Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(239)

Side by Side Diff: examples/python/__mojo__.py

Issue 988653002: Fix unused variable pylint warning. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | mojo/public/python/mojo_application/application_delegate.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2015 The Chromium Authors. All rights reserved. 1 # Copyright 2015 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 """Example python application implementing the Echo service.""" 5 """Example python application implementing the Echo service."""
6 6
7 import logging 7 import logging
8 8
9 import example_service_mojom 9 import example_service_mojom
10 from mojo_application import application_delegate 10 from mojo_application import application_delegate
11 from mojo_application import service_provider_impl 11 from mojo_application import service_provider_impl
12 from mojo_application import application_runner 12 from mojo_application import application_runner
13 13
14 import mojo_system 14 import mojo_system
15 15
16 class ExampleApp(application_delegate.ApplicationDelegate): 16 class ExampleApp(application_delegate.ApplicationDelegate):
17 def OnAcceptConnection(self, service_provider, requestor_url, 17 def OnAcceptConnection(self,
18 requestor_url,
19 resolved_url,
20 service_provider,
18 exposed_services): 21 exposed_services):
19 service_provider.AddService(ExampleServiceImpl) 22 service_provider.AddService(ExampleServiceImpl)
20 return True 23 return True
21 24
22 25
23 class ExampleServiceImpl(example_service_mojom.ExampleService): 26 class ExampleServiceImpl(example_service_mojom.ExampleService):
24 def Ping(self, ping_value): 27 def Ping(self, ping_value):
25 return ping_value 28 return ping_value
26 29
27 30
28 def MojoMain(app_request_handle): 31 def MojoMain(app_request_handle):
29 application_runner.RunMojoApplication(ExampleApp(), app_request_handle) 32 application_runner.RunMojoApplication(ExampleApp(), app_request_handle)
OLDNEW
« no previous file with comments | « no previous file | mojo/public/python/mojo_application/application_delegate.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698