HCE Project Python language Distributed Tasks Manager Application, Distributed Crawler Application and client API bindings.  2.0.0-chaika
Hierarchical Cluster Engine Python language binding
transport.Response.Response Class Reference

It's a wrapper similar to zmsg.hpp in sense of encapsulation of hce response message structure. More...

Inheritance diagram for transport.Response.Response:
Collaboration diagram for transport.Response.Response:

Public Member Functions

def __init__ (self, data, connect_identity=None)
 constructor parse data according to the protocol More...
 
def get_uid (self)
 get_uid More...
 
def get_body (self)
 get_body More...
 

Public Attributes

 connect_identity
 
 uid
 
 body
 

Detailed Description

It's a wrapper similar to zmsg.hpp in sense of encapsulation of hce response message structure.

Wrapper over hce response protocol - so it can raise AttributeError:
when construct from wrong protocol format

Definition at line 20 of file Response.py.

Constructor & Destructor Documentation

◆ __init__()

def transport.Response.Response.__init__ (   self,
  data,
  connect_identity = None 
)

constructor parse data according to the protocol

Parameters
identity- zmq socket identity
datarow data from zmq.socket
Returns
None or throw ResponseFormatErr

Definition at line 33 of file Response.py.

33  def __init__(self, data, connect_identity=None):
34  if len(data) < 2:
35  raise ResponseFormatErr(data)
36  self.connect_identity = connect_identity
37  self.uid = data[0]
38  self.body = data[1]
39 
40 
def __init__(self)
constructor
Definition: UIDGenerator.py:19

Member Function Documentation

◆ get_body()

def transport.Response.Response.get_body (   self)

get_body

return response body

Definition at line 51 of file Response.py.

51  def get_body(self):
52  return self.body
53 

◆ get_uid()

def transport.Response.Response.get_uid (   self)

get_uid

Returns
response uid

Definition at line 44 of file Response.py.

44  def get_uid(self):
45  return self.uid
46 
47 
def get_uid(self, idType=0)
get_uid
Definition: UIDGenerator.py:31

Member Data Documentation

◆ body

transport.Response.Response.body

Definition at line 38 of file Response.py.

◆ connect_identity

transport.Response.Response.connect_identity

Definition at line 36 of file Response.py.

◆ uid

transport.Response.Response.uid

Definition at line 37 of file Response.py.


The documentation for this class was generated from the following file: