ckbot :: ckmodule :: AbstractProtocol :: Class AbstractProtocol
[hide private]
[frames] | no frames]

Class AbstractProtocol

source code


abstract superclass of all Protocol classes

Protocol classes are responsible for generating the Protocol Node 
Adaptors for each module on the bus, when the bus is scanned. 
Protocols implement the transactions that the underlying communication
infrastructure supports, and typically maintain state representing any
incomplete transactions. 

AbstractProtocol subclasses must implement the following methods:
  p.update()
  p.hintNodes(nodes)
  p.generatePNA( nid )

AbstractProtocol instances must have the following data attributes:
  p.heartbeats -- dict -- nid to last heartbeat

Instance Methods [hide private]
 
__init__(self, bus=None)
Allow a bus parameter to be passed to all AbstractProtocol subclass constructors
source code
 
update(self)
*PURE* perform Protocol housekeeping operations
source code
 
hintNodes(self, nodes)
*PURE* use hint that specified nodes are available
source code
 
generatePNA(self, nid)
*PURE* Generate a ProtocolNodeAdaptor for the specified nid
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, bus=None)
(Constructor)

source code 

Allow a bus parameter to be passed to all AbstractProtocol subclass constructors

Overrides: object.__init__