Home | Trees | Index | Help |
|
---|
Package AccessGrid :: Module EventClient :: Class EventClient |
|
The Event Client maintains a client side connection to the Event Service to maintain state among a set of clients. This is done by sending events through the event service.
Method Summary | |
---|---|
The EventClient constructor takes a host, port. | |
__del__(self)
| |
DefaultCallback(self,
event)
| |
handleData(self,
pdata)
| |
Event processing thread. | |
readCallback(self,
arg,
handle,
result,
buf,
n)
| |
Asynch read callback. | |
RegisterCallback(self,
eventType,
callback)
| |
RegisterObject is short hand for registering multiple callbacks on the same object. | |
This method sends data to the Event Service. | |
Start(self)
| |
Register for asynch io. | |
Stop(self)
|
Class Variable Summary | |
---|---|
int |
bufsize = 4096 |
Method Details |
---|
__init__(self,
privateId,
location,
channel)
|
QueueThreadMain(self)Event processing thread. This thread blocks on a read from the client-local event queue (self.queue). Commands on the form are tuples where tuple[0] is the name of the command. Commands we process are quit: Terminate the event processing thread. call: Invoke a callback. The callback is tuple[1], the event to pass to it is tuple[2]. |
readCallbackWrap(self, arg, handle, result, buf, n)Asynch read callback. We just use this to wrap the call to the readCallback itself, because the callback invocation mechanism silently ignores exceptions. |
RegisterObject(self, object)RegisterObject is short hand for registering multiple callbacks on the same object. The object being registered has to define a table named callbacks that has event types as keys, and self.methods as values. Then these are automatically registered. |
Send(self, data)This method sends data to the Event Service. |
start(self)Register for asynch io. |
Class Variable Details |
---|
bufsize
|
Home | Trees | Index | Help |
|
---|
Generated by Epydoc 2.1 on Thu Apr 14 16:39:26 2005 | http://epydoc.sf.net |