aboutsummaryrefslogtreecommitdiffstats
path: root/lib/dominoRPC
diff options
context:
space:
mode:
authorUlas Kozat <ulas.kozat@gmail.com>2016-05-15 21:31:15 -0700
committerUlas Kozat <ulas.kozat@gmail.com>2016-05-15 21:43:21 -0700
commit7893dd02c15f2a727eb50887c9ddb829fc71f556 (patch)
tree54efcdadfda729ec4301537d264f6ea4298716e9 /lib/dominoRPC
parent06f85217ae3d5c9b429bad94827caed0641cd120 (diff)
Simple mapper/scheduler/partitioner functions implemented
Change-Id: I553b196943022451d8dc4984fe37b2b228c8f4cf Signed-off-by: Ulas C. Kozat <ulas.kozat@huawei.com>
Diffstat (limited to 'lib/dominoRPC')
-rwxr-xr-xlib/dominoRPC/Communication-remote129
-rw-r--r--lib/dominoRPC/Communication.py1196
-rw-r--r--lib/dominoRPC/Communication.pycbin0 -> 41494 bytes
-rw-r--r--lib/dominoRPC/__init__.py1
-rw-r--r--lib/dominoRPC/__init__.pycbin0 -> 181 bytes
-rw-r--r--lib/dominoRPC/constants.py27
-rw-r--r--lib/dominoRPC/constants.pycbin0 -> 719 bytes
-rw-r--r--lib/dominoRPC/ttypes.py1435
-rw-r--r--lib/dominoRPC/ttypes.pycbin0 -> 42261 bytes
9 files changed, 2788 insertions, 0 deletions
diff --git a/lib/dominoRPC/Communication-remote b/lib/dominoRPC/Communication-remote
new file mode 100755
index 0000000..77a96d7
--- /dev/null
+++ b/lib/dominoRPC/Communication-remote
@@ -0,0 +1,129 @@
+#!/usr/bin/env python
+#
+# Autogenerated by Thrift Compiler (0.9.3)
+#
+# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+#
+# options string: py
+#
+
+import sys
+import pprint
+from urlparse import urlparse
+from thrift.transport import TTransport
+from thrift.transport import TSocket
+from thrift.transport import TSSLSocket
+from thrift.transport import THttpClient
+from thrift.protocol import TBinaryProtocol
+
+from domino import Communication
+from domino.ttypes import *
+
+if len(sys.argv) <= 1 or sys.argv[1] == '--help':
+ print('')
+ print('Usage: ' + sys.argv[0] + ' [-h host[:port]] [-u url] [-f[ramed]] [-s[sl]] function [arg1 [arg2...]]')
+ print('')
+ print('Functions:')
+ print(' HeartBeatMessage d_heartbeat(HeartBeatMessage msg)')
+ print(' RegisterResponseMessage d_register(RegisterMessage msg)')
+ print(' SubscribeResponseMessage d_subscribe(SubscribeMessage msg)')
+ print(' PublishResponseMessage d_publish(PublishMessage msg)')
+ print(' PushResponseMessage d_push(PushMessage msg)')
+ print(' QueryResponseMessage d_query(QueryMessage msg)')
+ print('')
+ sys.exit(0)
+
+pp = pprint.PrettyPrinter(indent = 2)
+host = 'localhost'
+port = 9090
+uri = ''
+framed = False
+ssl = False
+http = False
+argi = 1
+
+if sys.argv[argi] == '-h':
+ parts = sys.argv[argi+1].split(':')
+ host = parts[0]
+ if len(parts) > 1:
+ port = int(parts[1])
+ argi += 2
+
+if sys.argv[argi] == '-u':
+ url = urlparse(sys.argv[argi+1])
+ parts = url[1].split(':')
+ host = parts[0]
+ if len(parts) > 1:
+ port = int(parts[1])
+ else:
+ port = 80
+ uri = url[2]
+ if url[4]:
+ uri += '?%s' % url[4]
+ http = True
+ argi += 2
+
+if sys.argv[argi] == '-f' or sys.argv[argi] == '-framed':
+ framed = True
+ argi += 1
+
+if sys.argv[argi] == '-s' or sys.argv[argi] == '-ssl':
+ ssl = True
+ argi += 1
+
+cmd = sys.argv[argi]
+args = sys.argv[argi+1:]
+
+if http:
+ transport = THttpClient.THttpClient(host, port, uri)
+else:
+ socket = TSSLSocket.TSSLSocket(host, port, validate=False) if ssl else TSocket.TSocket(host, port)
+ if framed:
+ transport = TTransport.TFramedTransport(socket)
+ else:
+ transport = TTransport.TBufferedTransport(socket)
+protocol = TBinaryProtocol.TBinaryProtocol(transport)
+client = Communication.Client(protocol)
+transport.open()
+
+if cmd == 'd_heartbeat':
+ if len(args) != 1:
+ print('d_heartbeat requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.d_heartbeat(eval(args[0]),))
+
+elif cmd == 'd_register':
+ if len(args) != 1:
+ print('d_register requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.d_register(eval(args[0]),))
+
+elif cmd == 'd_subscribe':
+ if len(args) != 1:
+ print('d_subscribe requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.d_subscribe(eval(args[0]),))
+
+elif cmd == 'd_publish':
+ if len(args) != 1:
+ print('d_publish requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.d_publish(eval(args[0]),))
+
+elif cmd == 'd_push':
+ if len(args) != 1:
+ print('d_push requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.d_push(eval(args[0]),))
+
+elif cmd == 'd_query':
+ if len(args) != 1:
+ print('d_query requires 1 args')
+ sys.exit(1)
+ pp.pprint(client.d_query(eval(args[0]),))
+
+else:
+ print('Unrecognized method %s' % cmd)
+ sys.exit(1)
+
+transport.close()
diff --git a/lib/dominoRPC/Communication.py b/lib/dominoRPC/Communication.py
new file mode 100644
index 0000000..2252bf7
--- /dev/null
+++ b/lib/dominoRPC/Communication.py
@@ -0,0 +1,1196 @@
+#
+# Autogenerated by Thrift Compiler (0.9.3)
+#
+# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+#
+# options string: py
+#
+
+from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+import logging
+from ttypes import *
+from thrift.Thrift import TProcessor
+from thrift.transport import TTransport
+from thrift.protocol import TBinaryProtocol, TProtocol
+try:
+ from thrift.protocol import fastbinary
+except:
+ fastbinary = None
+
+
+class Iface:
+ def d_heartbeat(self, msg):
+ """
+ A method definition looks like C code. It has a return type, arguments,
+ and optionally a list of exceptions that it may throw. Note that argument
+ lists and exception lists are specified using the exact same syntax as
+ field lists in struct or exception definitions.
+
+ Parameters:
+ - msg
+ """
+ pass
+
+ def d_register(self, msg):
+ """
+ Parameters:
+ - msg
+ """
+ pass
+
+ def d_subscribe(self, msg):
+ """
+ Parameters:
+ - msg
+ """
+ pass
+
+ def d_publish(self, msg):
+ """
+ Parameters:
+ - msg
+ """
+ pass
+
+ def d_push(self, msg):
+ """
+ Parameters:
+ - msg
+ """
+ pass
+
+ def d_query(self, msg):
+ """
+ Parameters:
+ - msg
+ """
+ pass
+
+
+class Client(Iface):
+ def __init__(self, iprot, oprot=None):
+ self._iprot = self._oprot = iprot
+ if oprot is not None:
+ self._oprot = oprot
+ self._seqid = 0
+
+ def d_heartbeat(self, msg):
+ """
+ A method definition looks like C code. It has a return type, arguments,
+ and optionally a list of exceptions that it may throw. Note that argument
+ lists and exception lists are specified using the exact same syntax as
+ field lists in struct or exception definitions.
+
+ Parameters:
+ - msg
+ """
+ self.send_d_heartbeat(msg)
+ return self.recv_d_heartbeat()
+
+ def send_d_heartbeat(self, msg):
+ self._oprot.writeMessageBegin('d_heartbeat', TMessageType.CALL, self._seqid)
+ args = d_heartbeat_args()
+ args.msg = msg
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_d_heartbeat(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = d_heartbeat_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "d_heartbeat failed: unknown result")
+
+ def d_register(self, msg):
+ """
+ Parameters:
+ - msg
+ """
+ self.send_d_register(msg)
+ return self.recv_d_register()
+
+ def send_d_register(self, msg):
+ self._oprot.writeMessageBegin('d_register', TMessageType.CALL, self._seqid)
+ args = d_register_args()
+ args.msg = msg
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_d_register(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = d_register_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "d_register failed: unknown result")
+
+ def d_subscribe(self, msg):
+ """
+ Parameters:
+ - msg
+ """
+ self.send_d_subscribe(msg)
+ return self.recv_d_subscribe()
+
+ def send_d_subscribe(self, msg):
+ self._oprot.writeMessageBegin('d_subscribe', TMessageType.CALL, self._seqid)
+ args = d_subscribe_args()
+ args.msg = msg
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_d_subscribe(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = d_subscribe_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "d_subscribe failed: unknown result")
+
+ def d_publish(self, msg):
+ """
+ Parameters:
+ - msg
+ """
+ self.send_d_publish(msg)
+ return self.recv_d_publish()
+
+ def send_d_publish(self, msg):
+ self._oprot.writeMessageBegin('d_publish', TMessageType.CALL, self._seqid)
+ args = d_publish_args()
+ args.msg = msg
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_d_publish(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = d_publish_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "d_publish failed: unknown result")
+
+ def d_push(self, msg):
+ """
+ Parameters:
+ - msg
+ """
+ self.send_d_push(msg)
+ return self.recv_d_push()
+
+ def send_d_push(self, msg):
+ self._oprot.writeMessageBegin('d_push', TMessageType.CALL, self._seqid)
+ args = d_push_args()
+ args.msg = msg
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_d_push(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = d_push_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "d_push failed: unknown result")
+
+ def d_query(self, msg):
+ """
+ Parameters:
+ - msg
+ """
+ self.send_d_query(msg)
+ return self.recv_d_query()
+
+ def send_d_query(self, msg):
+ self._oprot.writeMessageBegin('d_query', TMessageType.CALL, self._seqid)
+ args = d_query_args()
+ args.msg = msg
+ args.write(self._oprot)
+ self._oprot.writeMessageEnd()
+ self._oprot.trans.flush()
+
+ def recv_d_query(self):
+ iprot = self._iprot
+ (fname, mtype, rseqid) = iprot.readMessageBegin()
+ if mtype == TMessageType.EXCEPTION:
+ x = TApplicationException()
+ x.read(iprot)
+ iprot.readMessageEnd()
+ raise x
+ result = d_query_result()
+ result.read(iprot)
+ iprot.readMessageEnd()
+ if result.success is not None:
+ return result.success
+ raise TApplicationException(TApplicationException.MISSING_RESULT, "d_query failed: unknown result")
+
+
+class Processor(Iface, TProcessor):
+ def __init__(self, handler):
+ self._handler = handler
+ self._processMap = {}
+ self._processMap["d_heartbeat"] = Processor.process_d_heartbeat
+ self._processMap["d_register"] = Processor.process_d_register
+ self._processMap["d_subscribe"] = Processor.process_d_subscribe
+ self._processMap["d_publish"] = Processor.process_d_publish
+ self._processMap["d_push"] = Processor.process_d_push
+ self._processMap["d_query"] = Processor.process_d_query
+
+ def process(self, iprot, oprot):
+ (name, type, seqid) = iprot.readMessageBegin()
+ if name not in self._processMap:
+ iprot.skip(TType.STRUCT)
+ iprot.readMessageEnd()
+ x = TApplicationException(TApplicationException.UNKNOWN_METHOD, 'Unknown function %s' % (name))
+ oprot.writeMessageBegin(name, TMessageType.EXCEPTION, seqid)
+ x.write(oprot)
+ oprot.writeMessageEnd()
+ oprot.trans.flush()
+ return
+ else:
+ self._processMap[name](self, seqid, iprot, oprot)
+ return True
+
+ def process_d_heartbeat(self, seqid, iprot, oprot):
+ args = d_heartbeat_args()
+ args.read(iprot)
+ iprot.readMessageEnd()
+ result = d_heartbeat_result()
+ try:
+ result.success = self._handler.d_heartbeat(args.msg)
+ msg_type = TMessageType.REPLY
+ except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+ raise
+ except Exception as ex:
+ msg_type = TMessageType.EXCEPTION
+ logging.exception(ex)
+ result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+ oprot.writeMessageBegin("d_heartbeat", msg_type, seqid)
+ result.write(oprot)
+ oprot.writeMessageEnd()
+ oprot.trans.flush()
+
+ def process_d_register(self, seqid, iprot, oprot):
+ args = d_register_args()
+ args.read(iprot)
+ iprot.readMessageEnd()
+ result = d_register_result()
+ try:
+ result.success = self._handler.d_register(args.msg)
+ msg_type = TMessageType.REPLY
+ except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+ raise
+ except Exception as ex:
+ msg_type = TMessageType.EXCEPTION
+ logging.exception(ex)
+ result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+ oprot.writeMessageBegin("d_register", msg_type, seqid)
+ result.write(oprot)
+ oprot.writeMessageEnd()
+ oprot.trans.flush()
+
+ def process_d_subscribe(self, seqid, iprot, oprot):
+ args = d_subscribe_args()
+ args.read(iprot)
+ iprot.readMessageEnd()
+ result = d_subscribe_result()
+ try:
+ result.success = self._handler.d_subscribe(args.msg)
+ msg_type = TMessageType.REPLY
+ except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+ raise
+ except Exception as ex:
+ msg_type = TMessageType.EXCEPTION
+ logging.exception(ex)
+ result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+ oprot.writeMessageBegin("d_subscribe", msg_type, seqid)
+ result.write(oprot)
+ oprot.writeMessageEnd()
+ oprot.trans.flush()
+
+ def process_d_publish(self, seqid, iprot, oprot):
+ args = d_publish_args()
+ args.read(iprot)
+ iprot.readMessageEnd()
+ result = d_publish_result()
+ try:
+ result.success = self._handler.d_publish(args.msg)
+ msg_type = TMessageType.REPLY
+ except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+ raise
+ except Exception as ex:
+ msg_type = TMessageType.EXCEPTION
+ logging.exception(ex)
+ result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+ oprot.writeMessageBegin("d_publish", msg_type, seqid)
+ result.write(oprot)
+ oprot.writeMessageEnd()
+ oprot.trans.flush()
+
+ def process_d_push(self, seqid, iprot, oprot):
+ args = d_push_args()
+ args.read(iprot)
+ iprot.readMessageEnd()
+ result = d_push_result()
+ try:
+ result.success = self._handler.d_push(args.msg)
+ msg_type = TMessageType.REPLY
+ except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+ raise
+ except Exception as ex:
+ msg_type = TMessageType.EXCEPTION
+ logging.exception(ex)
+ result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+ oprot.writeMessageBegin("d_push", msg_type, seqid)
+ result.write(oprot)
+ oprot.writeMessageEnd()
+ oprot.trans.flush()
+
+ def process_d_query(self, seqid, iprot, oprot):
+ args = d_query_args()
+ args.read(iprot)
+ iprot.readMessageEnd()
+ result = d_query_result()
+ try:
+ result.success = self._handler.d_query(args.msg)
+ msg_type = TMessageType.REPLY
+ except (TTransport.TTransportException, KeyboardInterrupt, SystemExit):
+ raise
+ except Exception as ex:
+ msg_type = TMessageType.EXCEPTION
+ logging.exception(ex)
+ result = TApplicationException(TApplicationException.INTERNAL_ERROR, 'Internal error')
+ oprot.writeMessageBegin("d_query", msg_type, seqid)
+ result.write(oprot)
+ oprot.writeMessageEnd()
+ oprot.trans.flush()
+
+
+# HELPER FUNCTIONS AND STRUCTURES
+
+class d_heartbeat_args:
+ """
+ Attributes:
+ - msg
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRUCT, 'msg', (HeartBeatMessage, HeartBeatMessage.thrift_spec), None, ), # 1
+ )
+
+ def __init__(self, msg=None,):
+ self.msg = msg
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRUCT:
+ self.msg = HeartBeatMessage()
+ self.msg.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('d_heartbeat_args')
+ if self.msg is not None:
+ oprot.writeFieldBegin('msg', TType.STRUCT, 1)
+ self.msg.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.msg)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class d_heartbeat_result:
+ """
+ Attributes:
+ - success
+ """
+
+ thrift_spec = (
+ (0, TType.STRUCT, 'success', (HeartBeatMessage, HeartBeatMessage.thrift_spec), None, ), # 0
+ )
+
+ def __init__(self, success=None,):
+ self.success = success
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 0:
+ if ftype == TType.STRUCT:
+ self.success = HeartBeatMessage()
+ self.success.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('d_heartbeat_result')
+ if self.success is not None:
+ oprot.writeFieldBegin('success', TType.STRUCT, 0)
+ self.success.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.success)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class d_register_args:
+ """
+ Attributes:
+ - msg
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRUCT, 'msg', (RegisterMessage, RegisterMessage.thrift_spec), None, ), # 1
+ )
+
+ def __init__(self, msg=None,):
+ self.msg = msg
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRUCT:
+ self.msg = RegisterMessage()
+ self.msg.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('d_register_args')
+ if self.msg is not None:
+ oprot.writeFieldBegin('msg', TType.STRUCT, 1)
+ self.msg.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.msg)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class d_register_result:
+ """
+ Attributes:
+ - success
+ """
+
+ thrift_spec = (
+ (0, TType.STRUCT, 'success', (RegisterResponseMessage, RegisterResponseMessage.thrift_spec), None, ), # 0
+ )
+
+ def __init__(self, success=None,):
+ self.success = success
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 0:
+ if ftype == TType.STRUCT:
+ self.success = RegisterResponseMessage()
+ self.success.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('d_register_result')
+ if self.success is not None:
+ oprot.writeFieldBegin('success', TType.STRUCT, 0)
+ self.success.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.success)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class d_subscribe_args:
+ """
+ Attributes:
+ - msg
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRUCT, 'msg', (SubscribeMessage, SubscribeMessage.thrift_spec), None, ), # 1
+ )
+
+ def __init__(self, msg=None,):
+ self.msg = msg
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRUCT:
+ self.msg = SubscribeMessage()
+ self.msg.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('d_subscribe_args')
+ if self.msg is not None:
+ oprot.writeFieldBegin('msg', TType.STRUCT, 1)
+ self.msg.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.msg)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class d_subscribe_result:
+ """
+ Attributes:
+ - success
+ """
+
+ thrift_spec = (
+ (0, TType.STRUCT, 'success', (SubscribeResponseMessage, SubscribeResponseMessage.thrift_spec), None, ), # 0
+ )
+
+ def __init__(self, success=None,):
+ self.success = success
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 0:
+ if ftype == TType.STRUCT:
+ self.success = SubscribeResponseMessage()
+ self.success.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('d_subscribe_result')
+ if self.success is not None:
+ oprot.writeFieldBegin('success', TType.STRUCT, 0)
+ self.success.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.success)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class d_publish_args:
+ """
+ Attributes:
+ - msg
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRUCT, 'msg', (PublishMessage, PublishMessage.thrift_spec), None, ), # 1
+ )
+
+ def __init__(self, msg=None,):
+ self.msg = msg
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRUCT:
+ self.msg = PublishMessage()
+ self.msg.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('d_publish_args')
+ if self.msg is not None:
+ oprot.writeFieldBegin('msg', TType.STRUCT, 1)
+ self.msg.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.msg)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class d_publish_result:
+ """
+ Attributes:
+ - success
+ """
+
+ thrift_spec = (
+ (0, TType.STRUCT, 'success', (PublishResponseMessage, PublishResponseMessage.thrift_spec), None, ), # 0
+ )
+
+ def __init__(self, success=None,):
+ self.success = success
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 0:
+ if ftype == TType.STRUCT:
+ self.success = PublishResponseMessage()
+ self.success.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('d_publish_result')
+ if self.success is not None:
+ oprot.writeFieldBegin('success', TType.STRUCT, 0)
+ self.success.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.success)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class d_push_args:
+ """
+ Attributes:
+ - msg
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRUCT, 'msg', (PushMessage, PushMessage.thrift_spec), None, ), # 1
+ )
+
+ def __init__(self, msg=None,):
+ self.msg = msg
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRUCT:
+ self.msg = PushMessage()
+ self.msg.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('d_push_args')
+ if self.msg is not None:
+ oprot.writeFieldBegin('msg', TType.STRUCT, 1)
+ self.msg.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.msg)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class d_push_result:
+ """
+ Attributes:
+ - success
+ """
+
+ thrift_spec = (
+ (0, TType.STRUCT, 'success', (PushResponseMessage, PushResponseMessage.thrift_spec), None, ), # 0
+ )
+
+ def __init__(self, success=None,):
+ self.success = success
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 0:
+ if ftype == TType.STRUCT:
+ self.success = PushResponseMessage()
+ self.success.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('d_push_result')
+ if self.success is not None:
+ oprot.writeFieldBegin('success', TType.STRUCT, 0)
+ self.success.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.success)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class d_query_args:
+ """
+ Attributes:
+ - msg
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.STRUCT, 'msg', (QueryMessage, QueryMessage.thrift_spec), None, ), # 1
+ )
+
+ def __init__(self, msg=None,):
+ self.msg = msg
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.STRUCT:
+ self.msg = QueryMessage()
+ self.msg.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('d_query_args')
+ if self.msg is not None:
+ oprot.writeFieldBegin('msg', TType.STRUCT, 1)
+ self.msg.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.msg)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class d_query_result:
+ """
+ Attributes:
+ - success
+ """
+
+ thrift_spec = (
+ (0, TType.STRUCT, 'success', (QueryResponseMessage, QueryResponseMessage.thrift_spec), None, ), # 0
+ )
+
+ def __init__(self, success=None,):
+ self.success = success
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 0:
+ if ftype == TType.STRUCT:
+ self.success = QueryResponseMessage()
+ self.success.read(iprot)
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('d_query_result')
+ if self.success is not None:
+ oprot.writeFieldBegin('success', TType.STRUCT, 0)
+ self.success.write(oprot)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.success)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
diff --git a/lib/dominoRPC/Communication.pyc b/lib/dominoRPC/Communication.pyc
new file mode 100644
index 0000000..b697bc2
--- /dev/null
+++ b/lib/dominoRPC/Communication.pyc
Binary files differ
diff --git a/lib/dominoRPC/__init__.py b/lib/dominoRPC/__init__.py
new file mode 100644
index 0000000..e2212bc
--- /dev/null
+++ b/lib/dominoRPC/__init__.py
@@ -0,0 +1 @@
+__all__ = ['ttypes', 'constants', 'Communication']
diff --git a/lib/dominoRPC/__init__.pyc b/lib/dominoRPC/__init__.pyc
new file mode 100644
index 0000000..52cf85c
--- /dev/null
+++ b/lib/dominoRPC/__init__.pyc
Binary files differ
diff --git a/lib/dominoRPC/constants.py b/lib/dominoRPC/constants.py
new file mode 100644
index 0000000..5687d91
--- /dev/null
+++ b/lib/dominoRPC/constants.py
@@ -0,0 +1,27 @@
+#
+# Autogenerated by Thrift Compiler (0.9.3)
+#
+# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+#
+# options string: py
+#
+
+from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+from ttypes import *
+
+HEART_BEAT = 1
+REGISTER = 2
+REGISTER_RESPONSE = 3
+SUBSCRIBE = 4
+SUBSCRIBE_RESPONSE = 5
+PUBLISH = 6
+PUBLISH_RESPONSE = 7
+PUSH = 8
+PUSH_RESPONSE = 9
+QUERY = 10
+QUERY_RESPONSE = 11
+SUCCESS = 1
+FAILED = 2
+APPEND = 0
+OVERWRITE = 1
+DELETE = 2
diff --git a/lib/dominoRPC/constants.pyc b/lib/dominoRPC/constants.pyc
new file mode 100644
index 0000000..2a494a7
--- /dev/null
+++ b/lib/dominoRPC/constants.pyc
Binary files differ
diff --git a/lib/dominoRPC/ttypes.py b/lib/dominoRPC/ttypes.py
new file mode 100644
index 0000000..8a80d5f
--- /dev/null
+++ b/lib/dominoRPC/ttypes.py
@@ -0,0 +1,1435 @@
+#
+# Autogenerated by Thrift Compiler (0.9.3)
+#
+# DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+#
+# options string: py
+#
+
+from thrift.Thrift import TType, TMessageType, TException, TApplicationException
+
+from thrift.transport import TTransport
+from thrift.protocol import TBinaryProtocol, TProtocol
+try:
+ from thrift.protocol import fastbinary
+except:
+ fastbinary = None
+
+
+
+class HeartBeatMessage:
+ """
+ Domino sends periodic heartbeats from
+ Domino Clients and Domino Server echos
+
+ Attributes:
+ - messageType
+ - domino_udid
+ - seq_no
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BYTE, 'messageType', None, 1, ), # 1
+ (2, TType.I64, 'domino_udid', None, None, ), # 2
+ (3, TType.I64, 'seq_no', None, None, ), # 3
+ )
+
+ def __init__(self, messageType=thrift_spec[1][4], domino_udid=None, seq_no=None,):
+ if messageType is self.thrift_spec[1][4]:
+ messageType = 1
+ self.messageType = messageType
+ self.domino_udid = domino_udid
+ self.seq_no = seq_no
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BYTE:
+ self.messageType = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.domino_udid = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I64:
+ self.seq_no = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('HeartBeatMessage')
+ if self.messageType is not None:
+ oprot.writeFieldBegin('messageType', TType.BYTE, 1)
+ oprot.writeByte(self.messageType)
+ oprot.writeFieldEnd()
+ if self.domino_udid is not None:
+ oprot.writeFieldBegin('domino_udid', TType.I64, 2)
+ oprot.writeI64(self.domino_udid)
+ oprot.writeFieldEnd()
+ if self.seq_no is not None:
+ oprot.writeFieldBegin('seq_no', TType.I64, 3)
+ oprot.writeI64(self.seq_no)
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.messageType)
+ value = (value * 31) ^ hash(self.domino_udid)
+ value = (value * 31) ^ hash(self.seq_no)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class RegisterMessage:
+ """
+ Domino Clients must first register with
+ Domino Server. Clients can ask for a specific
+ Unique Domino ID (UDID)
+
+ Attributes:
+ - messageType
+ - domino_udid_desired
+ - seq_no
+ - ipaddr
+ - tcpport
+ - supported_templates
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BYTE, 'messageType', None, 2, ), # 1
+ (2, TType.I64, 'domino_udid_desired', None, None, ), # 2
+ (3, TType.I64, 'seq_no', None, None, ), # 3
+ (4, TType.STRING, 'ipaddr', None, None, ), # 4
+ (5, TType.I16, 'tcpport', None, None, ), # 5
+ (6, TType.LIST, 'supported_templates', (TType.STRING,None), None, ), # 6
+ )
+
+ def __init__(self, messageType=thrift_spec[1][4], domino_udid_desired=None, seq_no=None, ipaddr=None, tcpport=None, supported_templates=None,):
+ if messageType is self.thrift_spec[1][4]:
+ messageType = 2
+ self.messageType = messageType
+ self.domino_udid_desired = domino_udid_desired
+ self.seq_no = seq_no
+ self.ipaddr = ipaddr
+ self.tcpport = tcpport
+ self.supported_templates = supported_templates
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BYTE:
+ self.messageType = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.domino_udid_desired = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I64:
+ self.seq_no = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.ipaddr = iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.I16:
+ self.tcpport = iprot.readI16()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.LIST:
+ self.supported_templates = []
+ (_etype3, _size0) = iprot.readListBegin()
+ for _i4 in xrange(_size0):
+ _elem5 = iprot.readString()
+ self.supported_templates.append(_elem5)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('RegisterMessage')
+ if self.messageType is not None:
+ oprot.writeFieldBegin('messageType', TType.BYTE, 1)
+ oprot.writeByte(self.messageType)
+ oprot.writeFieldEnd()
+ if self.domino_udid_desired is not None:
+ oprot.writeFieldBegin('domino_udid_desired', TType.I64, 2)
+ oprot.writeI64(self.domino_udid_desired)
+ oprot.writeFieldEnd()
+ if self.seq_no is not None:
+ oprot.writeFieldBegin('seq_no', TType.I64, 3)
+ oprot.writeI64(self.seq_no)
+ oprot.writeFieldEnd()
+ if self.ipaddr is not None:
+ oprot.writeFieldBegin('ipaddr', TType.STRING, 4)
+ oprot.writeString(self.ipaddr)
+ oprot.writeFieldEnd()
+ if self.tcpport is not None:
+ oprot.writeFieldBegin('tcpport', TType.I16, 5)
+ oprot.writeI16(self.tcpport)
+ oprot.writeFieldEnd()
+ if self.supported_templates is not None:
+ oprot.writeFieldBegin('supported_templates', TType.LIST, 6)
+ oprot.writeListBegin(TType.STRING, len(self.supported_templates))
+ for iter6 in self.supported_templates:
+ oprot.writeString(iter6)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.messageType)
+ value = (value * 31) ^ hash(self.domino_udid_desired)
+ value = (value * 31) ^ hash(self.seq_no)
+ value = (value * 31) ^ hash(self.ipaddr)
+ value = (value * 31) ^ hash(self.tcpport)
+ value = (value * 31) ^ hash(self.supported_templates)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class RegisterResponseMessage:
+ """
+ Attributes:
+ - messageType
+ - domino_udid
+ - domino_udid_assigned
+ - seq_no
+ - responseCode
+ - comments
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BYTE, 'messageType', None, 3, ), # 1
+ (2, TType.I64, 'domino_udid', None, None, ), # 2
+ (3, TType.I64, 'domino_udid_assigned', None, None, ), # 3
+ (4, TType.I64, 'seq_no', None, None, ), # 4
+ (5, TType.BYTE, 'responseCode', None, None, ), # 5
+ (6, TType.LIST, 'comments', (TType.STRING,None), None, ), # 6
+ )
+
+ def __init__(self, messageType=thrift_spec[1][4], domino_udid=None, domino_udid_assigned=None, seq_no=None, responseCode=None, comments=None,):
+ if messageType is self.thrift_spec[1][4]:
+ messageType = 3
+ self.messageType = messageType
+ self.domino_udid = domino_udid
+ self.domino_udid_assigned = domino_udid_assigned
+ self.seq_no = seq_no
+ self.responseCode = responseCode
+ self.comments = comments
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BYTE:
+ self.messageType = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.domino_udid = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I64:
+ self.domino_udid_assigned = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.I64:
+ self.seq_no = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.BYTE:
+ self.responseCode = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.LIST:
+ self.comments = []
+ (_etype10, _size7) = iprot.readListBegin()
+ for _i11 in xrange(_size7):
+ _elem12 = iprot.readString()
+ self.comments.append(_elem12)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('RegisterResponseMessage')
+ if self.messageType is not None:
+ oprot.writeFieldBegin('messageType', TType.BYTE, 1)
+ oprot.writeByte(self.messageType)
+ oprot.writeFieldEnd()
+ if self.domino_udid is not None:
+ oprot.writeFieldBegin('domino_udid', TType.I64, 2)
+ oprot.writeI64(self.domino_udid)
+ oprot.writeFieldEnd()
+ if self.domino_udid_assigned is not None:
+ oprot.writeFieldBegin('domino_udid_assigned', TType.I64, 3)
+ oprot.writeI64(self.domino_udid_assigned)
+ oprot.writeFieldEnd()
+ if self.seq_no is not None:
+ oprot.writeFieldBegin('seq_no', TType.I64, 4)
+ oprot.writeI64(self.seq_no)
+ oprot.writeFieldEnd()
+ if self.responseCode is not None:
+ oprot.writeFieldBegin('responseCode', TType.BYTE, 5)
+ oprot.writeByte(self.responseCode)
+ oprot.writeFieldEnd()
+ if self.comments is not None:
+ oprot.writeFieldBegin('comments', TType.LIST, 6)
+ oprot.writeListBegin(TType.STRING, len(self.comments))
+ for iter13 in self.comments:
+ oprot.writeString(iter13)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.messageType)
+ value = (value * 31) ^ hash(self.domino_udid)
+ value = (value * 31) ^ hash(self.domino_udid_assigned)
+ value = (value * 31) ^ hash(self.seq_no)
+ value = (value * 31) ^ hash(self.responseCode)
+ value = (value * 31) ^ hash(self.comments)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class SubscribeMessage:
+ """
+ Attributes:
+ - messageType
+ - domino_udid
+ - seq_no
+ - template_op
+ - supported_template_types
+ - label_op
+ - labels
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BYTE, 'messageType', None, 4, ), # 1
+ (2, TType.I64, 'domino_udid', None, None, ), # 2
+ (3, TType.I64, 'seq_no', None, None, ), # 3
+ (4, TType.BYTE, 'template_op', None, None, ), # 4
+ (5, TType.LIST, 'supported_template_types', (TType.STRING,None), None, ), # 5
+ (6, TType.BYTE, 'label_op', None, None, ), # 6
+ (7, TType.LIST, 'labels', (TType.STRING,None), None, ), # 7
+ )
+
+ def __init__(self, messageType=thrift_spec[1][4], domino_udid=None, seq_no=None, template_op=None, supported_template_types=None, label_op=None, labels=None,):
+ if messageType is self.thrift_spec[1][4]:
+ messageType = 4
+ self.messageType = messageType
+ self.domino_udid = domino_udid
+ self.seq_no = seq_no
+ self.template_op = template_op
+ self.supported_template_types = supported_template_types
+ self.label_op = label_op
+ self.labels = labels
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BYTE:
+ self.messageType = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.domino_udid = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I64:
+ self.seq_no = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.BYTE:
+ self.template_op = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.supported_template_types = []
+ (_etype17, _size14) = iprot.readListBegin()
+ for _i18 in xrange(_size14):
+ _elem19 = iprot.readString()
+ self.supported_template_types.append(_elem19)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ elif fid == 6:
+ if ftype == TType.BYTE:
+ self.label_op = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 7:
+ if ftype == TType.LIST:
+ self.labels = []
+ (_etype23, _size20) = iprot.readListBegin()
+ for _i24 in xrange(_size20):
+ _elem25 = iprot.readString()
+ self.labels.append(_elem25)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('SubscribeMessage')
+ if self.messageType is not None:
+ oprot.writeFieldBegin('messageType', TType.BYTE, 1)
+ oprot.writeByte(self.messageType)
+ oprot.writeFieldEnd()
+ if self.domino_udid is not None:
+ oprot.writeFieldBegin('domino_udid', TType.I64, 2)
+ oprot.writeI64(self.domino_udid)
+ oprot.writeFieldEnd()
+ if self.seq_no is not None:
+ oprot.writeFieldBegin('seq_no', TType.I64, 3)
+ oprot.writeI64(self.seq_no)
+ oprot.writeFieldEnd()
+ if self.template_op is not None:
+ oprot.writeFieldBegin('template_op', TType.BYTE, 4)
+ oprot.writeByte(self.template_op)
+ oprot.writeFieldEnd()
+ if self.supported_template_types is not None:
+ oprot.writeFieldBegin('supported_template_types', TType.LIST, 5)
+ oprot.writeListBegin(TType.STRING, len(self.supported_template_types))
+ for iter26 in self.supported_template_types:
+ oprot.writeString(iter26)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ if self.label_op is not None:
+ oprot.writeFieldBegin('label_op', TType.BYTE, 6)
+ oprot.writeByte(self.label_op)
+ oprot.writeFieldEnd()
+ if self.labels is not None:
+ oprot.writeFieldBegin('labels', TType.LIST, 7)
+ oprot.writeListBegin(TType.STRING, len(self.labels))
+ for iter27 in self.labels:
+ oprot.writeString(iter27)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.messageType)
+ value = (value * 31) ^ hash(self.domino_udid)
+ value = (value * 31) ^ hash(self.seq_no)
+ value = (value * 31) ^ hash(self.template_op)
+ value = (value * 31) ^ hash(self.supported_template_types)
+ value = (value * 31) ^ hash(self.label_op)
+ value = (value * 31) ^ hash(self.labels)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class SubscribeResponseMessage:
+ """
+ Attributes:
+ - messageType
+ - domino_udid
+ - seq_no
+ - responseCode
+ - comments
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BYTE, 'messageType', None, 5, ), # 1
+ (2, TType.I64, 'domino_udid', None, None, ), # 2
+ (3, TType.I64, 'seq_no', None, None, ), # 3
+ (4, TType.BYTE, 'responseCode', None, None, ), # 4
+ (5, TType.LIST, 'comments', (TType.STRING,None), None, ), # 5
+ )
+
+ def __init__(self, messageType=thrift_spec[1][4], domino_udid=None, seq_no=None, responseCode=None, comments=None,):
+ if messageType is self.thrift_spec[1][4]:
+ messageType = 5
+ self.messageType = messageType
+ self.domino_udid = domino_udid
+ self.seq_no = seq_no
+ self.responseCode = responseCode
+ self.comments = comments
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BYTE:
+ self.messageType = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.domino_udid = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I64:
+ self.seq_no = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.BYTE:
+ self.responseCode = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.comments = []
+ (_etype31, _size28) = iprot.readListBegin()
+ for _i32 in xrange(_size28):
+ _elem33 = iprot.readString()
+ self.comments.append(_elem33)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('SubscribeResponseMessage')
+ if self.messageType is not None:
+ oprot.writeFieldBegin('messageType', TType.BYTE, 1)
+ oprot.writeByte(self.messageType)
+ oprot.writeFieldEnd()
+ if self.domino_udid is not None:
+ oprot.writeFieldBegin('domino_udid', TType.I64, 2)
+ oprot.writeI64(self.domino_udid)
+ oprot.writeFieldEnd()
+ if self.seq_no is not None:
+ oprot.writeFieldBegin('seq_no', TType.I64, 3)
+ oprot.writeI64(self.seq_no)
+ oprot.writeFieldEnd()
+ if self.responseCode is not None:
+ oprot.writeFieldBegin('responseCode', TType.BYTE, 4)
+ oprot.writeByte(self.responseCode)
+ oprot.writeFieldEnd()
+ if self.comments is not None:
+ oprot.writeFieldBegin('comments', TType.LIST, 5)
+ oprot.writeListBegin(TType.STRING, len(self.comments))
+ for iter34 in self.comments:
+ oprot.writeString(iter34)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.messageType)
+ value = (value * 31) ^ hash(self.domino_udid)
+ value = (value * 31) ^ hash(self.seq_no)
+ value = (value * 31) ^ hash(self.responseCode)
+ value = (value * 31) ^ hash(self.comments)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class PublishMessage:
+ """
+ Attributes:
+ - messageType
+ - domino_udid
+ - seq_no
+ - template_type
+ - template
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BYTE, 'messageType', None, 6, ), # 1
+ (2, TType.I64, 'domino_udid', None, None, ), # 2
+ (3, TType.I64, 'seq_no', None, None, ), # 3
+ (4, TType.STRING, 'template_type', None, None, ), # 4
+ (5, TType.LIST, 'template', (TType.STRING,None), None, ), # 5
+ )
+
+ def __init__(self, messageType=thrift_spec[1][4], domino_udid=None, seq_no=None, template_type=None, template=None,):
+ if messageType is self.thrift_spec[1][4]:
+ messageType = 6
+ self.messageType = messageType
+ self.domino_udid = domino_udid
+ self.seq_no = seq_no
+ self.template_type = template_type
+ self.template = template
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BYTE:
+ self.messageType = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.domino_udid = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I64:
+ self.seq_no = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.template_type = iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.template = []
+ (_etype38, _size35) = iprot.readListBegin()
+ for _i39 in xrange(_size35):
+ _elem40 = iprot.readString()
+ self.template.append(_elem40)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('PublishMessage')
+ if self.messageType is not None:
+ oprot.writeFieldBegin('messageType', TType.BYTE, 1)
+ oprot.writeByte(self.messageType)
+ oprot.writeFieldEnd()
+ if self.domino_udid is not None:
+ oprot.writeFieldBegin('domino_udid', TType.I64, 2)
+ oprot.writeI64(self.domino_udid)
+ oprot.writeFieldEnd()
+ if self.seq_no is not None:
+ oprot.writeFieldBegin('seq_no', TType.I64, 3)
+ oprot.writeI64(self.seq_no)
+ oprot.writeFieldEnd()
+ if self.template_type is not None:
+ oprot.writeFieldBegin('template_type', TType.STRING, 4)
+ oprot.writeString(self.template_type)
+ oprot.writeFieldEnd()
+ if self.template is not None:
+ oprot.writeFieldBegin('template', TType.LIST, 5)
+ oprot.writeListBegin(TType.STRING, len(self.template))
+ for iter41 in self.template:
+ oprot.writeString(iter41)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.messageType)
+ value = (value * 31) ^ hash(self.domino_udid)
+ value = (value * 31) ^ hash(self.seq_no)
+ value = (value * 31) ^ hash(self.template_type)
+ value = (value * 31) ^ hash(self.template)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class PublishResponseMessage:
+ """
+ Attributes:
+ - messageType
+ - domino_udid
+ - seq_no
+ - responseCode
+ - comments
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BYTE, 'messageType', None, 7, ), # 1
+ (2, TType.I64, 'domino_udid', None, None, ), # 2
+ (3, TType.I64, 'seq_no', None, None, ), # 3
+ (4, TType.BYTE, 'responseCode', None, None, ), # 4
+ (5, TType.LIST, 'comments', (TType.STRING,None), None, ), # 5
+ )
+
+ def __init__(self, messageType=thrift_spec[1][4], domino_udid=None, seq_no=None, responseCode=None, comments=None,):
+ if messageType is self.thrift_spec[1][4]:
+ messageType = 7
+ self.messageType = messageType
+ self.domino_udid = domino_udid
+ self.seq_no = seq_no
+ self.responseCode = responseCode
+ self.comments = comments
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BYTE:
+ self.messageType = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.domino_udid = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I64:
+ self.seq_no = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.BYTE:
+ self.responseCode = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.comments = []
+ (_etype45, _size42) = iprot.readListBegin()
+ for _i46 in xrange(_size42):
+ _elem47 = iprot.readString()
+ self.comments.append(_elem47)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('PublishResponseMessage')
+ if self.messageType is not None:
+ oprot.writeFieldBegin('messageType', TType.BYTE, 1)
+ oprot.writeByte(self.messageType)
+ oprot.writeFieldEnd()
+ if self.domino_udid is not None:
+ oprot.writeFieldBegin('domino_udid', TType.I64, 2)
+ oprot.writeI64(self.domino_udid)
+ oprot.writeFieldEnd()
+ if self.seq_no is not None:
+ oprot.writeFieldBegin('seq_no', TType.I64, 3)
+ oprot.writeI64(self.seq_no)
+ oprot.writeFieldEnd()
+ if self.responseCode is not None:
+ oprot.writeFieldBegin('responseCode', TType.BYTE, 4)
+ oprot.writeByte(self.responseCode)
+ oprot.writeFieldEnd()
+ if self.comments is not None:
+ oprot.writeFieldBegin('comments', TType.LIST, 5)
+ oprot.writeListBegin(TType.STRING, len(self.comments))
+ for iter48 in self.comments:
+ oprot.writeString(iter48)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.messageType)
+ value = (value * 31) ^ hash(self.domino_udid)
+ value = (value * 31) ^ hash(self.seq_no)
+ value = (value * 31) ^ hash(self.responseCode)
+ value = (value * 31) ^ hash(self.comments)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class PushMessage:
+ """
+ Attributes:
+ - messageType
+ - domino_udid
+ - seq_no
+ - template_type
+ - template
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BYTE, 'messageType', None, 8, ), # 1
+ (2, TType.I64, 'domino_udid', None, None, ), # 2
+ (3, TType.I64, 'seq_no', None, None, ), # 3
+ (4, TType.STRING, 'template_type', None, None, ), # 4
+ (5, TType.LIST, 'template', (TType.STRING,None), None, ), # 5
+ )
+
+ def __init__(self, messageType=thrift_spec[1][4], domino_udid=None, seq_no=None, template_type=None, template=None,):
+ if messageType is self.thrift_spec[1][4]:
+ messageType = 8
+ self.messageType = messageType
+ self.domino_udid = domino_udid
+ self.seq_no = seq_no
+ self.template_type = template_type
+ self.template = template
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BYTE:
+ self.messageType = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.domino_udid = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I64:
+ self.seq_no = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.STRING:
+ self.template_type = iprot.readString()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.template = []
+ (_etype52, _size49) = iprot.readListBegin()
+ for _i53 in xrange(_size49):
+ _elem54 = iprot.readString()
+ self.template.append(_elem54)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('PushMessage')
+ if self.messageType is not None:
+ oprot.writeFieldBegin('messageType', TType.BYTE, 1)
+ oprot.writeByte(self.messageType)
+ oprot.writeFieldEnd()
+ if self.domino_udid is not None:
+ oprot.writeFieldBegin('domino_udid', TType.I64, 2)
+ oprot.writeI64(self.domino_udid)
+ oprot.writeFieldEnd()
+ if self.seq_no is not None:
+ oprot.writeFieldBegin('seq_no', TType.I64, 3)
+ oprot.writeI64(self.seq_no)
+ oprot.writeFieldEnd()
+ if self.template_type is not None:
+ oprot.writeFieldBegin('template_type', TType.STRING, 4)
+ oprot.writeString(self.template_type)
+ oprot.writeFieldEnd()
+ if self.template is not None:
+ oprot.writeFieldBegin('template', TType.LIST, 5)
+ oprot.writeListBegin(TType.STRING, len(self.template))
+ for iter55 in self.template:
+ oprot.writeString(iter55)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.messageType)
+ value = (value * 31) ^ hash(self.domino_udid)
+ value = (value * 31) ^ hash(self.seq_no)
+ value = (value * 31) ^ hash(self.template_type)
+ value = (value * 31) ^ hash(self.template)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class PushResponseMessage:
+ """
+ Attributes:
+ - messageType
+ - domino_udid
+ - seq_no
+ - responseCode
+ - comments
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BYTE, 'messageType', None, 9, ), # 1
+ (2, TType.I64, 'domino_udid', None, None, ), # 2
+ (3, TType.I64, 'seq_no', None, None, ), # 3
+ (4, TType.BYTE, 'responseCode', None, None, ), # 4
+ (5, TType.LIST, 'comments', (TType.STRING,None), None, ), # 5
+ )
+
+ def __init__(self, messageType=thrift_spec[1][4], domino_udid=None, seq_no=None, responseCode=None, comments=None,):
+ if messageType is self.thrift_spec[1][4]:
+ messageType = 9
+ self.messageType = messageType
+ self.domino_udid = domino_udid
+ self.seq_no = seq_no
+ self.responseCode = responseCode
+ self.comments = comments
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BYTE:
+ self.messageType = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.domino_udid = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I64:
+ self.seq_no = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.BYTE:
+ self.responseCode = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.comments = []
+ (_etype59, _size56) = iprot.readListBegin()
+ for _i60 in xrange(_size56):
+ _elem61 = iprot.readString()
+ self.comments.append(_elem61)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('PushResponseMessage')
+ if self.messageType is not None:
+ oprot.writeFieldBegin('messageType', TType.BYTE, 1)
+ oprot.writeByte(self.messageType)
+ oprot.writeFieldEnd()
+ if self.domino_udid is not None:
+ oprot.writeFieldBegin('domino_udid', TType.I64, 2)
+ oprot.writeI64(self.domino_udid)
+ oprot.writeFieldEnd()
+ if self.seq_no is not None:
+ oprot.writeFieldBegin('seq_no', TType.I64, 3)
+ oprot.writeI64(self.seq_no)
+ oprot.writeFieldEnd()
+ if self.responseCode is not None:
+ oprot.writeFieldBegin('responseCode', TType.BYTE, 4)
+ oprot.writeByte(self.responseCode)
+ oprot.writeFieldEnd()
+ if self.comments is not None:
+ oprot.writeFieldBegin('comments', TType.LIST, 5)
+ oprot.writeListBegin(TType.STRING, len(self.comments))
+ for iter62 in self.comments:
+ oprot.writeString(iter62)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.messageType)
+ value = (value * 31) ^ hash(self.domino_udid)
+ value = (value * 31) ^ hash(self.seq_no)
+ value = (value * 31) ^ hash(self.responseCode)
+ value = (value * 31) ^ hash(self.comments)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class QueryMessage:
+ """
+ Attributes:
+ - messageType
+ - domino_udid
+ - seq_no
+ - queryString
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BYTE, 'messageType', None, 10, ), # 1
+ (2, TType.I64, 'domino_udid', None, None, ), # 2
+ (3, TType.I64, 'seq_no', None, None, ), # 3
+ (4, TType.LIST, 'queryString', (TType.STRING,None), None, ), # 4
+ )
+
+ def __init__(self, messageType=thrift_spec[1][4], domino_udid=None, seq_no=None, queryString=None,):
+ if messageType is self.thrift_spec[1][4]:
+ messageType = 10
+ self.messageType = messageType
+ self.domino_udid = domino_udid
+ self.seq_no = seq_no
+ self.queryString = queryString
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BYTE:
+ self.messageType = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.domino_udid = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I64:
+ self.seq_no = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.LIST:
+ self.queryString = []
+ (_etype66, _size63) = iprot.readListBegin()
+ for _i67 in xrange(_size63):
+ _elem68 = iprot.readString()
+ self.queryString.append(_elem68)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('QueryMessage')
+ if self.messageType is not None:
+ oprot.writeFieldBegin('messageType', TType.BYTE, 1)
+ oprot.writeByte(self.messageType)
+ oprot.writeFieldEnd()
+ if self.domino_udid is not None:
+ oprot.writeFieldBegin('domino_udid', TType.I64, 2)
+ oprot.writeI64(self.domino_udid)
+ oprot.writeFieldEnd()
+ if self.seq_no is not None:
+ oprot.writeFieldBegin('seq_no', TType.I64, 3)
+ oprot.writeI64(self.seq_no)
+ oprot.writeFieldEnd()
+ if self.queryString is not None:
+ oprot.writeFieldBegin('queryString', TType.LIST, 4)
+ oprot.writeListBegin(TType.STRING, len(self.queryString))
+ for iter69 in self.queryString:
+ oprot.writeString(iter69)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.messageType)
+ value = (value * 31) ^ hash(self.domino_udid)
+ value = (value * 31) ^ hash(self.seq_no)
+ value = (value * 31) ^ hash(self.queryString)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
+
+class QueryResponseMessage:
+ """
+ Attributes:
+ - messageType
+ - domino_udid
+ - seq_no
+ - responseCode
+ - queryResponse
+ """
+
+ thrift_spec = (
+ None, # 0
+ (1, TType.BYTE, 'messageType', None, 11, ), # 1
+ (2, TType.I64, 'domino_udid', None, None, ), # 2
+ (3, TType.I64, 'seq_no', None, None, ), # 3
+ (4, TType.BYTE, 'responseCode', None, None, ), # 4
+ (5, TType.LIST, 'queryResponse', (TType.STRING,None), None, ), # 5
+ )
+
+ def __init__(self, messageType=thrift_spec[1][4], domino_udid=None, seq_no=None, responseCode=None, queryResponse=None,):
+ if messageType is self.thrift_spec[1][4]:
+ messageType = 11
+ self.messageType = messageType
+ self.domino_udid = domino_udid
+ self.seq_no = seq_no
+ self.responseCode = responseCode
+ self.queryResponse = queryResponse
+
+ def read(self, iprot):
+ if iprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and isinstance(iprot.trans, TTransport.CReadableTransport) and self.thrift_spec is not None and fastbinary is not None:
+ fastbinary.decode_binary(self, iprot.trans, (self.__class__, self.thrift_spec))
+ return
+ iprot.readStructBegin()
+ while True:
+ (fname, ftype, fid) = iprot.readFieldBegin()
+ if ftype == TType.STOP:
+ break
+ if fid == 1:
+ if ftype == TType.BYTE:
+ self.messageType = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 2:
+ if ftype == TType.I64:
+ self.domino_udid = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 3:
+ if ftype == TType.I64:
+ self.seq_no = iprot.readI64()
+ else:
+ iprot.skip(ftype)
+ elif fid == 4:
+ if ftype == TType.BYTE:
+ self.responseCode = iprot.readByte()
+ else:
+ iprot.skip(ftype)
+ elif fid == 5:
+ if ftype == TType.LIST:
+ self.queryResponse = []
+ (_etype73, _size70) = iprot.readListBegin()
+ for _i74 in xrange(_size70):
+ _elem75 = iprot.readString()
+ self.queryResponse.append(_elem75)
+ iprot.readListEnd()
+ else:
+ iprot.skip(ftype)
+ else:
+ iprot.skip(ftype)
+ iprot.readFieldEnd()
+ iprot.readStructEnd()
+
+ def write(self, oprot):
+ if oprot.__class__ == TBinaryProtocol.TBinaryProtocolAccelerated and self.thrift_spec is not None and fastbinary is not None:
+ oprot.trans.write(fastbinary.encode_binary(self, (self.__class__, self.thrift_spec)))
+ return
+ oprot.writeStructBegin('QueryResponseMessage')
+ if self.messageType is not None:
+ oprot.writeFieldBegin('messageType', TType.BYTE, 1)
+ oprot.writeByte(self.messageType)
+ oprot.writeFieldEnd()
+ if self.domino_udid is not None:
+ oprot.writeFieldBegin('domino_udid', TType.I64, 2)
+ oprot.writeI64(self.domino_udid)
+ oprot.writeFieldEnd()
+ if self.seq_no is not None:
+ oprot.writeFieldBegin('seq_no', TType.I64, 3)
+ oprot.writeI64(self.seq_no)
+ oprot.writeFieldEnd()
+ if self.responseCode is not None:
+ oprot.writeFieldBegin('responseCode', TType.BYTE, 4)
+ oprot.writeByte(self.responseCode)
+ oprot.writeFieldEnd()
+ if self.queryResponse is not None:
+ oprot.writeFieldBegin('queryResponse', TType.LIST, 5)
+ oprot.writeListBegin(TType.STRING, len(self.queryResponse))
+ for iter76 in self.queryResponse:
+ oprot.writeString(iter76)
+ oprot.writeListEnd()
+ oprot.writeFieldEnd()
+ oprot.writeFieldStop()
+ oprot.writeStructEnd()
+
+ def validate(self):
+ return
+
+
+ def __hash__(self):
+ value = 17
+ value = (value * 31) ^ hash(self.messageType)
+ value = (value * 31) ^ hash(self.domino_udid)
+ value = (value * 31) ^ hash(self.seq_no)
+ value = (value * 31) ^ hash(self.responseCode)
+ value = (value * 31) ^ hash(self.queryResponse)
+ return value
+
+ def __repr__(self):
+ L = ['%s=%r' % (key, value)
+ for key, value in self.__dict__.iteritems()]
+ return '%s(%s)' % (self.__class__.__name__, ', '.join(L))
+
+ def __eq__(self, other):
+ return isinstance(other, self.__class__) and self.__dict__ == other.__dict__
+
+ def __ne__(self, other):
+ return not (self == other)
diff --git a/lib/dominoRPC/ttypes.pyc b/lib/dominoRPC/ttypes.pyc
new file mode 100644
index 0000000..be548d1
--- /dev/null
+++ b/lib/dominoRPC/ttypes.pyc
Binary files differ