Package isnLib :: Package net :: Module imgClient :: Class imgClient
[show private | hide private]
[frames | no frames]

Class imgClient


this class represents a remote imgServer connection to the local machine. should hold all data known about the remote server, and abstract some requests/connection code, etc
Method Summary
  __init__(self, env, ndata)
  __str__(self)
  connect(self)
  debug(self, msg)
  errID(self, reason)
  errKarma(self, reason)
  errRoot(self, reason)
  errStatus(self, reason)
  gotID(self, id)
  gotKarma(self, k)
  gotRoot(self, root)
  gotStatus(self, stat)
  persist(self)
should return an object to be serialized to disk.
  summon(self, data)
brings this instance into a working (or at least properly initialized) state from the data parameter, and tries to connect

Class Variable Summary
list persistAttrs = ['addr', 'port', 'isLocal']
dict stateDict = {0: 'connecting', 1: 'disconnected', 2: 'con...
int stDead = 1                                                                     
int stRooted = 2                                                                     
int stRooting = 0                                                                     

Method Details

persist(self)

should return an object to be serialized to disk. Later, a new imgClient will be reconstructed from this data.

Every change to this method should have its analogue change on self.summon()

summon(self, data)

brings this instance into a working (or at least properly initialized) state from the data parameter, and tries to connect

Class Variable Details

persistAttrs

Type:
list
Value:
['addr', 'port', 'isLocal']                                            

stateDict

Type:
dict
Value:
{0: 'connecting', 1: 'disconnected', 2: 'connected'}                   

stDead

Type:
int
Value:
1                                                                     

stRooted

Type:
int
Value:
2                                                                     

stRooting

Type:
int
Value:
0                                                                     

Generated by Epydoc 2.0 on Thu Dec 25 10:59:56 2003 http://epydoc.sf.net