equip.data
Class DataDelegatePeer
java.lang.Object
equip.runtime.Object
equip.runtime.ValueBase
equip.data.DataCallback
equip.data.DataDelegatePeer
- All Implemented Interfaces:
- java.lang.Cloneable
- public class DataDelegatePeer
- extends DataCallback
Internal implementation class; works with DataDelegate
to handle a dataspace replica's association with another dataspace
replica. For example, a client will have an instance of this class
to deal with its relationship to its server, and a server will have
one instance of this class for each current client.
| Methods inherited from class java.lang.Object |
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
dataDelegate
protected DataDelegate dataDelegate
peerId
protected GUID peerId
responsible
protected GUID responsible
serverFlag
boolean serverFlag
policy
protected PeerPolicy policy
session
protected DataSession session
outboundEvents
protected java.util.Vector outboundEvents
nextOutboundSequenceNo
protected int nextOutboundSequenceNo
outboundEventLock
protected java.lang.Object outboundEventLock
notifiedItemIds
protected java.util.Hashtable notifiedItemIds
lastNotifiedEvent
protected Event lastNotifiedEvent
debug
boolean debug
debugDuplicate
boolean debugDuplicate
eventRepeatCount
protected int eventRepeatCount
cancelCallback
DataDelegatePeerCancel cancelCallback
DataDelegatePeer
public DataDelegatePeer(DataDelegate dataDelegate,
GUID peerId,
boolean serverFlag)
shutdown
public void shutdown()
getServerFlag
public boolean getServerFlag()
getPeerId
public GUID getPeerId()
getResponsible
public GUID getResponsible()
handleEvent
public void handleEvent(Event event)
outputEvent
public void outputEvent(Event event)
getNextOutboundEvent
public DataDelegatePeer.OutboundEvent getNextOutboundEvent()
wakeOutbound
public void wakeOutbound()
removeOutboundEvent
public void removeOutboundEvent(int sequenceNo)
notify
public void notify(Event event,
EventPattern pattern,
boolean patternDeleted,
DataSession session,
ValueBase closure)
- Description copied from class:
DataCallback
- notification of a matched event or pseudo event.
Note, should really have more info here, e.g. dataspace.
- Specified by:
notify in class DataCallback
- Parameters:
event - The matched event being enacted by the dataspace.pattern - The pattern that was matched.patternDeleted - Whether the pattern has been deleted
as a result of the event, e.g. matched.session - The DataSession generating this callback.closure - As provided when the DataSession was
created.
setStatus
public void setStatus(boolean serverFlag,
boolean clientConnectedFlag,
boolean clientSlowFlag)
handleAddPatterns
protected void handleAddPatterns(EventPattern[] patterns)
handleAddPattern
protected void handleAddPattern(EventPattern pattern)
finalize
protected void finalize()
cleanup
public void cleanup()
setCancelCallback
public void setCancelCallback(DataDelegatePeerCancel cb)
getNumOutboundEvents
public int getNumOutboundEvents()
- return number of outbound events not passed to connection