clearpath::horizon::payloads-new::Payload Class Reference

Inheritance diagram for clearpath::horizon::payloads-new::Payload:
Inheritance graph
[legend]

List of all members.

Public Member Functions

def __init__
def __str__
def data
def fields
def parse
def validate

Detailed Description

Definition at line 14 of file payloads-new.py.


Member Function Documentation

def clearpath::horizon::payloads-new::Payload::__init__ (   self,
  kwargs 
)

Definition at line 15 of file payloads-new.py.

def clearpath::horizon::payloads-new::Payload::__str__ (   self  ) 
Prints a basic human-readable output, using formats and units for
fields based on the self.meta information from the Payload.fields
initializer.

Definition at line 26 of file payloads-new.py.

def clearpath::horizon::payloads-new::Payload::data (   self  ) 
Payloads which may be sent in outbound messages will implement this
method, which produces a list of bytes. For most messages, the data()
output will be identical to what is expected for parse(). However, not
all the messages are symmetrical!

Definition at line 83 of file payloads-new.py.

def clearpath::horizon::payloads-new::Payload::fields (   fieldstrs  ) 
Returns pointer to a SubPayload class which inherits from Payload, but also
has a namedtuple mixin with the specified fields, and also a special
meta attribute which provides hints to Payload about the fields and units
and so-on. Usage:
m = Payload.fields('field units format title').

Definition at line 53 of file payloads-new.py.

def clearpath::horizon::payloads-new::Payload::parse (   cls,
  data 
)
Payloads which implement this may be received on the wire, and
this method will parse the list of bytes and return a Payload object.

Definition at line 78 of file payloads-new.py.

def clearpath::horizon::payloads-new::Payload::validate (   self  ) 
All payloads must implement validation, using Fields.check()

Definition at line 90 of file payloads-new.py.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Properties


clearpath_base
Author(s): Mike Purvis
autogenerated on Fri Jan 11 10:11:36 2013