Trying to init events server raises when given port is not free.
[leap_pycommon.git] / src / leap / common / events / events_pb2.py
1 # Generated by the protocol buffer compiler.  DO NOT EDIT!
2 # source: events.proto
3
4 from google.protobuf.internal import enum_type_wrapper
5 from google.protobuf import descriptor as _descriptor
6 from google.protobuf import message as _message
7 from google.protobuf import reflection as _reflection
8 from google.protobuf import service as _service
9 from google.protobuf import service_reflection
10 from google.protobuf import descriptor_pb2
11 # @@protoc_insertion_point(imports)
12
13
14 DESCRIPTOR = _descriptor.FileDescriptor(
15     name='events.proto',
16     package='leap.common.events',
17     serialized_pb='\n\x0c\x65vents.proto\x12\x12leap.common.events\"\x97\x01\n\rSignalRequest\x12(\n\x05\x65vent\x18\x01 \x02(\x0e\x32\x19.leap.common.events.Event\x12\x0f\n\x07\x63ontent\x18\x02 \x02(\t\x12\x12\n\nmac_method\x18\x03 \x02(\t\x12\x0b\n\x03mac\x18\x04 \x02(\x0c\x12\x12\n\nenc_method\x18\x05 \x01(\t\x12\x16\n\x0e\x65rror_occurred\x18\x06 \x01(\x08\"j\n\x0fRegisterRequest\x12(\n\x05\x65vent\x18\x01 \x02(\x0e\x32\x19.leap.common.events.Event\x12\x0c\n\x04port\x18\x02 \x02(\x05\x12\x12\n\nmac_method\x18\x03 \x02(\t\x12\x0b\n\x03mac\x18\x04 \x02(\x0c\"l\n\x11UnregisterRequest\x12(\n\x05\x65vent\x18\x01 \x02(\x0e\x32\x19.leap.common.events.Event\x12\x0c\n\x04port\x18\x02 \x02(\x05\x12\x12\n\nmac_method\x18\x03 \x02(\t\x12\x0b\n\x03mac\x18\x04 \x02(\x0c\"\r\n\x0bPingRequest\"\x82\x01\n\rEventResponse\x12\x38\n\x06status\x18\x01 \x02(\x0e\x32(.leap.common.events.EventResponse.Status\x12\x0e\n\x06result\x18\x02 \x01(\t\"\'\n\x06Status\x12\x06\n\x02OK\x10\x01\x12\n\n\x06UNAUTH\x10\x02\x12\t\n\x05\x45RROR\x10\x03*\xe7\x02\n\x05\x45vent\x12\x15\n\x11\x43LIENT_SESSION_ID\x10\x01\x12\x0e\n\nCLIENT_UID\x10\x02\x12\x19\n\x15SOLEDAD_CREATING_KEYS\x10\x03\x12\x1e\n\x1aSOLEDAD_DONE_CREATING_KEYS\x10\x04\x12\x1a\n\x16SOLEDAD_UPLOADING_KEYS\x10\x05\x12\x1f\n\x1bSOLEDAD_DONE_UPLOADING_KEYS\x10\x06\x12\x1c\n\x18SOLEDAD_DOWNLOADING_KEYS\x10\x07\x12!\n\x1dSOLEDAD_DONE_DOWNLOADING_KEYS\x10\x08\x12\x1c\n\x18SOLEDAD_NEW_DATA_TO_SYNC\x10\t\x12\x1a\n\x16SOLEDAD_DONE_DATA_SYNC\x10\n\x12\x17\n\x13UPDATER_NEW_UPDATES\x10\x0b\x12\x19\n\x15UPDATER_DONE_UPDATING\x10\x0c\x12\x10\n\x0cRAISE_WINDOW\x10\r2\xdd\x02\n\x13\x45ventsServerService\x12J\n\x04ping\x12\x1f.leap.common.events.PingRequest\x1a!.leap.common.events.EventResponse\x12R\n\x08register\x12#.leap.common.events.RegisterRequest\x1a!.leap.common.events.EventResponse\x12V\n\nunregister\x12%.leap.common.events.UnregisterRequest\x1a!.leap.common.events.EventResponse\x12N\n\x06signal\x12!.leap.common.events.SignalRequest\x1a!.leap.common.events.EventResponse2\xb1\x01\n\x13\x45ventsClientService\x12J\n\x04ping\x12\x1f.leap.common.events.PingRequest\x1a!.leap.common.events.EventResponse\x12N\n\x06signal\x12!.leap.common.events.SignalRequest\x1a!.leap.common.events.EventResponseB\x03\x90\x01\x01')
18
19 _EVENT = _descriptor.EnumDescriptor(
20     name='Event',
21     full_name='leap.common.events.Event',
22     filename=None,
23     file=DESCRIPTOR,
24     values=[
25         _descriptor.EnumValueDescriptor(
26             name='CLIENT_SESSION_ID', index=0, number=1,
27             options=None,
28             type=None),
29         _descriptor.EnumValueDescriptor(
30             name='CLIENT_UID', index=1, number=2,
31             options=None,
32             type=None),
33         _descriptor.EnumValueDescriptor(
34             name='SOLEDAD_CREATING_KEYS', index=2, number=3,
35             options=None,
36             type=None),
37         _descriptor.EnumValueDescriptor(
38             name='SOLEDAD_DONE_CREATING_KEYS', index=3, number=4,
39             options=None,
40             type=None),
41         _descriptor.EnumValueDescriptor(
42             name='SOLEDAD_UPLOADING_KEYS', index=4, number=5,
43             options=None,
44             type=None),
45         _descriptor.EnumValueDescriptor(
46             name='SOLEDAD_DONE_UPLOADING_KEYS', index=5, number=6,
47             options=None,
48             type=None),
49         _descriptor.EnumValueDescriptor(
50             name='SOLEDAD_DOWNLOADING_KEYS', index=6, number=7,
51             options=None,
52             type=None),
53         _descriptor.EnumValueDescriptor(
54             name='SOLEDAD_DONE_DOWNLOADING_KEYS', index=7, number=8,
55             options=None,
56             type=None),
57         _descriptor.EnumValueDescriptor(
58             name='SOLEDAD_NEW_DATA_TO_SYNC', index=8, number=9,
59             options=None,
60             type=None),
61         _descriptor.EnumValueDescriptor(
62             name='SOLEDAD_DONE_DATA_SYNC', index=9, number=10,
63             options=None,
64             type=None),
65         _descriptor.EnumValueDescriptor(
66             name='UPDATER_NEW_UPDATES', index=10, number=11,
67             options=None,
68             type=None),
69         _descriptor.EnumValueDescriptor(
70             name='UPDATER_DONE_UPDATING', index=11, number=12,
71             options=None,
72             type=None),
73         _descriptor.EnumValueDescriptor(
74             name='RAISE_WINDOW', index=12, number=13,
75             options=None,
76             type=None),
77     ],
78     containing_type=None,
79     options=None,
80     serialized_start=557,
81     serialized_end=916,
82 )
83
84 Event = enum_type_wrapper.EnumTypeWrapper(_EVENT)
85 CLIENT_SESSION_ID = 1
86 CLIENT_UID = 2
87 SOLEDAD_CREATING_KEYS = 3
88 SOLEDAD_DONE_CREATING_KEYS = 4
89 SOLEDAD_UPLOADING_KEYS = 5
90 SOLEDAD_DONE_UPLOADING_KEYS = 6
91 SOLEDAD_DOWNLOADING_KEYS = 7
92 SOLEDAD_DONE_DOWNLOADING_KEYS = 8
93 SOLEDAD_NEW_DATA_TO_SYNC = 9
94 SOLEDAD_DONE_DATA_SYNC = 10
95 UPDATER_NEW_UPDATES = 11
96 UPDATER_DONE_UPDATING = 12
97 RAISE_WINDOW = 13
98
99
100 _EVENTRESPONSE_STATUS = _descriptor.EnumDescriptor(
101     name='Status',
102     full_name='leap.common.events.EventResponse.Status',
103     filename=None,
104     file=DESCRIPTOR,
105     values=[
106         _descriptor.EnumValueDescriptor(
107             name='OK', index=0, number=1,
108             options=None,
109             type=None),
110         _descriptor.EnumValueDescriptor(
111             name='UNAUTH', index=1, number=2,
112             options=None,
113             type=None),
114         _descriptor.EnumValueDescriptor(
115             name='ERROR', index=2, number=3,
116             options=None,
117             type=None),
118     ],
119     containing_type=None,
120     options=None,
121     serialized_start=515,
122     serialized_end=554,
123 )
124
125
126 _SIGNALREQUEST = _descriptor.Descriptor(
127     name='SignalRequest',
128     full_name='leap.common.events.SignalRequest',
129     filename=None,
130     file=DESCRIPTOR,
131     containing_type=None,
132     fields=[
133         _descriptor.FieldDescriptor(
134             name='event', full_name='leap.common.events.SignalRequest.event', index=0,
135             number=1, type=14, cpp_type=8, label=2,
136             has_default_value=False, default_value=1,
137             message_type=None, enum_type=None, containing_type=None,
138             is_extension=False, extension_scope=None,
139             options=None),
140         _descriptor.FieldDescriptor(
141             name='content', full_name='leap.common.events.SignalRequest.content', index=1,
142             number=2, type=9, cpp_type=9, label=2,
143             has_default_value=False, default_value=unicode("", "utf-8"),
144             message_type=None, enum_type=None, containing_type=None,
145             is_extension=False, extension_scope=None,
146             options=None),
147         _descriptor.FieldDescriptor(
148             name='mac_method', full_name='leap.common.events.SignalRequest.mac_method', index=2,
149             number=3, type=9, cpp_type=9, label=2,
150             has_default_value=False, default_value=unicode("", "utf-8"),
151             message_type=None, enum_type=None, containing_type=None,
152             is_extension=False, extension_scope=None,
153             options=None),
154         _descriptor.FieldDescriptor(
155             name='mac', full_name='leap.common.events.SignalRequest.mac', index=3,
156             number=4, type=12, cpp_type=9, label=2,
157             has_default_value=False, default_value="",
158             message_type=None, enum_type=None, containing_type=None,
159             is_extension=False, extension_scope=None,
160             options=None),
161         _descriptor.FieldDescriptor(
162             name='enc_method', full_name='leap.common.events.SignalRequest.enc_method', index=4,
163             number=5, type=9, cpp_type=9, label=1,
164             has_default_value=False, default_value=unicode("", "utf-8"),
165             message_type=None, enum_type=None, containing_type=None,
166             is_extension=False, extension_scope=None,
167             options=None),
168         _descriptor.FieldDescriptor(
169             name='error_occurred', full_name='leap.common.events.SignalRequest.error_occurred', index=5,
170             number=6, type=8, cpp_type=7, label=1,
171             has_default_value=False, default_value=False,
172             message_type=None, enum_type=None, containing_type=None,
173             is_extension=False, extension_scope=None,
174             options=None),
175     ],
176     extensions=[
177     ],
178     nested_types=[],
179     enum_types=[
180     ],
181     options=None,
182     is_extendable=False,
183     extension_ranges=[],
184     serialized_start=37,
185     serialized_end=188,
186 )
187
188
189 _REGISTERREQUEST = _descriptor.Descriptor(
190     name='RegisterRequest',
191     full_name='leap.common.events.RegisterRequest',
192     filename=None,
193     file=DESCRIPTOR,
194     containing_type=None,
195     fields=[
196         _descriptor.FieldDescriptor(
197             name='event', full_name='leap.common.events.RegisterRequest.event', index=0,
198             number=1, type=14, cpp_type=8, label=2,
199             has_default_value=False, default_value=1,
200             message_type=None, enum_type=None, containing_type=None,
201             is_extension=False, extension_scope=None,
202             options=None),
203         _descriptor.FieldDescriptor(
204             name='port', full_name='leap.common.events.RegisterRequest.port', index=1,
205             number=2, type=5, cpp_type=1, label=2,
206             has_default_value=False, default_value=0,
207             message_type=None, enum_type=None, containing_type=None,
208             is_extension=False, extension_scope=None,
209             options=None),
210         _descriptor.FieldDescriptor(
211             name='mac_method', full_name='leap.common.events.RegisterRequest.mac_method', index=2,
212             number=3, type=9, cpp_type=9, label=2,
213             has_default_value=False, default_value=unicode("", "utf-8"),
214             message_type=None, enum_type=None, containing_type=None,
215             is_extension=False, extension_scope=None,
216             options=None),
217         _descriptor.FieldDescriptor(
218             name='mac', full_name='leap.common.events.RegisterRequest.mac', index=3,
219             number=4, type=12, cpp_type=9, label=2,
220             has_default_value=False, default_value="",
221             message_type=None, enum_type=None, containing_type=None,
222             is_extension=False, extension_scope=None,
223             options=None),
224     ],
225     extensions=[
226     ],
227     nested_types=[],
228     enum_types=[
229     ],
230     options=None,
231     is_extendable=False,
232     extension_ranges=[],
233     serialized_start=190,
234     serialized_end=296,
235 )
236
237
238 _UNREGISTERREQUEST = _descriptor.Descriptor(
239     name='UnregisterRequest',
240     full_name='leap.common.events.UnregisterRequest',
241     filename=None,
242     file=DESCRIPTOR,
243     containing_type=None,
244     fields=[
245         _descriptor.FieldDescriptor(
246             name='event', full_name='leap.common.events.UnregisterRequest.event', index=0,
247             number=1, type=14, cpp_type=8, label=2,
248             has_default_value=False, default_value=1,
249             message_type=None, enum_type=None, containing_type=None,
250             is_extension=False, extension_scope=None,
251             options=None),
252         _descriptor.FieldDescriptor(
253             name='port', full_name='leap.common.events.UnregisterRequest.port', index=1,
254             number=2, type=5, cpp_type=1, label=2,
255             has_default_value=False, default_value=0,
256             message_type=None, enum_type=None, containing_type=None,
257             is_extension=False, extension_scope=None,
258             options=None),
259         _descriptor.FieldDescriptor(
260             name='mac_method', full_name='leap.common.events.UnregisterRequest.mac_method', index=2,
261             number=3, type=9, cpp_type=9, label=2,
262             has_default_value=False, default_value=unicode("", "utf-8"),
263             message_type=None, enum_type=None, containing_type=None,
264             is_extension=False, extension_scope=None,
265             options=None),
266         _descriptor.FieldDescriptor(
267             name='mac', full_name='leap.common.events.UnregisterRequest.mac', index=3,
268             number=4, type=12, cpp_type=9, label=2,
269             has_default_value=False, default_value="",
270             message_type=None, enum_type=None, containing_type=None,
271             is_extension=False, extension_scope=None,
272             options=None),
273     ],
274     extensions=[
275     ],
276     nested_types=[],
277     enum_types=[
278     ],
279     options=None,
280     is_extendable=False,
281     extension_ranges=[],
282     serialized_start=298,
283     serialized_end=406,
284 )
285
286
287 _PINGREQUEST = _descriptor.Descriptor(
288     name='PingRequest',
289     full_name='leap.common.events.PingRequest',
290     filename=None,
291     file=DESCRIPTOR,
292     containing_type=None,
293     fields=[
294     ],
295     extensions=[
296     ],
297     nested_types=[],
298     enum_types=[
299     ],
300     options=None,
301     is_extendable=False,
302     extension_ranges=[],
303     serialized_start=408,
304     serialized_end=421,
305 )
306
307
308 _EVENTRESPONSE = _descriptor.Descriptor(
309     name='EventResponse',
310     full_name='leap.common.events.EventResponse',
311     filename=None,
312     file=DESCRIPTOR,
313     containing_type=None,
314     fields=[
315         _descriptor.FieldDescriptor(
316             name='status', full_name='leap.common.events.EventResponse.status', index=0,
317             number=1, type=14, cpp_type=8, label=2,
318             has_default_value=False, default_value=1,
319             message_type=None, enum_type=None, containing_type=None,
320             is_extension=False, extension_scope=None,
321             options=None),
322         _descriptor.FieldDescriptor(
323             name='result', full_name='leap.common.events.EventResponse.result', index=1,
324             number=2, type=9, cpp_type=9, label=1,
325             has_default_value=False, default_value=unicode("", "utf-8"),
326             message_type=None, enum_type=None, containing_type=None,
327             is_extension=False, extension_scope=None,
328             options=None),
329     ],
330     extensions=[
331     ],
332     nested_types=[],
333     enum_types=[
334         _EVENTRESPONSE_STATUS,
335     ],
336     options=None,
337     is_extendable=False,
338     extension_ranges=[],
339     serialized_start=424,
340     serialized_end=554,
341 )
342
343 _SIGNALREQUEST.fields_by_name['event'].enum_type = _EVENT
344 _REGISTERREQUEST.fields_by_name['event'].enum_type = _EVENT
345 _UNREGISTERREQUEST.fields_by_name['event'].enum_type = _EVENT
346 _EVENTRESPONSE.fields_by_name['status'].enum_type = _EVENTRESPONSE_STATUS
347 _EVENTRESPONSE_STATUS.containing_type = _EVENTRESPONSE
348 DESCRIPTOR.message_types_by_name['SignalRequest'] = _SIGNALREQUEST
349 DESCRIPTOR.message_types_by_name['RegisterRequest'] = _REGISTERREQUEST
350 DESCRIPTOR.message_types_by_name['UnregisterRequest'] = _UNREGISTERREQUEST
351 DESCRIPTOR.message_types_by_name['PingRequest'] = _PINGREQUEST
352 DESCRIPTOR.message_types_by_name['EventResponse'] = _EVENTRESPONSE
353
354
355 class SignalRequest(_message.Message):
356     __metaclass__ = _reflection.GeneratedProtocolMessageType
357     DESCRIPTOR = _SIGNALREQUEST
358
359     # @@protoc_insertion_point(class_scope:leap.common.events.SignalRequest)
360
361
362 class RegisterRequest(_message.Message):
363     __metaclass__ = _reflection.GeneratedProtocolMessageType
364     DESCRIPTOR = _REGISTERREQUEST
365
366     # @@protoc_insertion_point(class_scope:leap.common.events.RegisterRequest)
367
368
369 class UnregisterRequest(_message.Message):
370     __metaclass__ = _reflection.GeneratedProtocolMessageType
371     DESCRIPTOR = _UNREGISTERREQUEST
372
373     # @@protoc_insertion_point(class_scope:leap.common.events.UnregisterRequest)
374
375
376 class PingRequest(_message.Message):
377     __metaclass__ = _reflection.GeneratedProtocolMessageType
378     DESCRIPTOR = _PINGREQUEST
379
380     # @@protoc_insertion_point(class_scope:leap.common.events.PingRequest)
381
382
383 class EventResponse(_message.Message):
384     __metaclass__ = _reflection.GeneratedProtocolMessageType
385     DESCRIPTOR = _EVENTRESPONSE
386
387     # @@protoc_insertion_point(class_scope:leap.common.events.EventResponse)
388
389
390 DESCRIPTOR.has_options = True
391 DESCRIPTOR._options = _descriptor._ParseOptions(
392     descriptor_pb2.FileOptions(), '\220\001\001')
393
394 _EVENTSSERVERSERVICE = _descriptor.ServiceDescriptor(
395     name='EventsServerService',
396     full_name='leap.common.events.EventsServerService',
397     file=DESCRIPTOR,
398     index=0,
399     options=None,
400     serialized_start=919,
401     serialized_end=1268,
402     methods=[
403         _descriptor.MethodDescriptor(
404             name='ping',
405             full_name='leap.common.events.EventsServerService.ping',
406             index=0,
407             containing_service=None,
408             input_type=_PINGREQUEST,
409             output_type=_EVENTRESPONSE,
410             options=None,
411         ),
412         _descriptor.MethodDescriptor(
413             name='register',
414             full_name='leap.common.events.EventsServerService.register',
415             index=1,
416             containing_service=None,
417             input_type=_REGISTERREQUEST,
418             output_type=_EVENTRESPONSE,
419             options=None,
420         ),
421         _descriptor.MethodDescriptor(
422             name='unregister',
423             full_name='leap.common.events.EventsServerService.unregister',
424             index=2,
425             containing_service=None,
426             input_type=_UNREGISTERREQUEST,
427             output_type=_EVENTRESPONSE,
428             options=None,
429         ),
430         _descriptor.MethodDescriptor(
431             name='signal',
432             full_name='leap.common.events.EventsServerService.signal',
433             index=3,
434             containing_service=None,
435             input_type=_SIGNALREQUEST,
436             output_type=_EVENTRESPONSE,
437             options=None,
438         ),
439     ])
440
441
442 class EventsServerService(_service.Service):
443     __metaclass__ = service_reflection.GeneratedServiceType
444     DESCRIPTOR = _EVENTSSERVERSERVICE
445
446
447 class EventsServerService_Stub(EventsServerService):
448     __metaclass__ = service_reflection.GeneratedServiceStubType
449     DESCRIPTOR = _EVENTSSERVERSERVICE
450
451
452 _EVENTSCLIENTSERVICE = _descriptor.ServiceDescriptor(
453     name='EventsClientService',
454     full_name='leap.common.events.EventsClientService',
455     file=DESCRIPTOR,
456     index=1,
457     options=None,
458     serialized_start=1271,
459     serialized_end=1448,
460     methods=[
461         _descriptor.MethodDescriptor(
462             name='ping',
463             full_name='leap.common.events.EventsClientService.ping',
464             index=0,
465             containing_service=None,
466             input_type=_PINGREQUEST,
467             output_type=_EVENTRESPONSE,
468             options=None,
469         ),
470         _descriptor.MethodDescriptor(
471             name='signal',
472             full_name='leap.common.events.EventsClientService.signal',
473             index=1,
474             containing_service=None,
475             input_type=_SIGNALREQUEST,
476             output_type=_EVENTRESPONSE,
477             options=None,
478         ),
479     ])
480
481
482 class EventsClientService(_service.Service):
483     __metaclass__ = service_reflection.GeneratedServiceType
484     DESCRIPTOR = _EVENTSCLIENTSERVICE
485
486
487 class EventsClientService_Stub(EventsClientService):
488     __metaclass__ = service_reflection.GeneratedServiceStubType
489     DESCRIPTOR = _EVENTSCLIENTSERVICE
490
491 # @@protoc_insertion_point(module_scope)