Package com.adobe.xfa
Class Dispatcher
- java.lang.Object
-
- com.adobe.xfa.Dispatcher
-
- All Implemented Interfaces:
Peer
- Direct Known Subclasses:
ScriptDispatcher
public abstract class Dispatcher extends java.lang.Object implements Peer
-
-
Field Summary
-
Fields inherited from interface com.adobe.xfa.ut.Peer
ATTR_CHANGED, CHILD_ADDED, CHILD_REMOVED, DESCENDENT_ADDED, DESCENDENT_ATTR_CHANGED, DESCENDENT_REMOVED, DESCENDENT_VALUE_CHANGED, PARENT_CHANGED, PERMS_LOCK_CLEARED, PERMS_LOCK_SET, PROTO_ATTR_CHANGED, PROTO_CHILD_ADDED, PROTO_CHILD_REMOVED, PROTO_DESCENDENT_ADDED, PROTO_DESCENDENT_ATTR_CHANGED, PROTO_DESCENDENT_REMOVED, PROTO_DESCENDENT_VALUE_CHANGED, PROTO_VALUE_CHANGED, UPDATED, VALUE_CHANGED
-
-
Constructor Summary
Constructors Constructor Description Dispatcher(Element poActionContextNode, java.lang.String sEventContext, int nEventID, EventManager poEventManager)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voidaddPeer(Peer peerNode)Add a peer node to be notified of state changes.voidaddPeeredNode(Peer peer)voidclearPeers()Removes this node from all peer relationships.voiddeafen()Makes this peer deaf to any updateFromPeer calls made by notifyPeersElementgetActionContextNode()abstract java.lang.StringgetDispatcherType()java.lang.StringgetEventContext()ObjgetEventContextObj()intgetEventID()EventManagergetEventManager()booleangetListenToDescendents()booleangetOccurring()java.lang.StringgetParameter(int nParam)PeergetPeer(int nPeer)return the requested peerbooleangetRecurring()booleanisDeaf()Checks if this peer is deaf.booleanisMute()Checks if this peer is mute.voidmute()Makes this peer no longer notify its peers when notifyPeers is calledvoidnotifyPeers(int eventType, java.lang.String arg1, java.lang.Object arg2)Sends notification to the peer nodes that this object has changed.voidpeerRemoved(Peer peer)Called when this Peer is removed frompeer.voidremovePeer(Peer oPeerNode)Remove a peer node from the notification list.voidremovePeeredNode(Peer poPeer)voidsetEventContextObj(Obj poObject)voidsetEventManager(EventManager poEventManager)voidsetListenToDescendents(boolean bListenToDescendents)voidsetOccurring(boolean bOccurring)voidsetRecurring(boolean bRecurring)voidunDeafen()Allows this peer to receive updateFromPeer callsvoidunMute()Allows this peer to notify its peers when notifyPeers is called.voidupdateFromPeer(java.lang.Object oPeerNode, int eventType, java.lang.String arg1, java.lang.Object arg2)This method will be called by the peer whenever its state changes.
-
-
-
Constructor Detail
-
Dispatcher
public Dispatcher(Element poActionContextNode, java.lang.String sEventContext, int nEventID, EventManager poEventManager)
-
-
Method Detail
-
addPeer
public void addPeer(Peer peerNode)
Description copied from interface:PeerAdd a peer node to be notified of state changes.
-
addPeeredNode
public void addPeeredNode(Peer peer)
- Specified by:
addPeeredNodein interfacePeer
-
clearPeers
public void clearPeers()
Description copied from interface:PeerRemoves this node from all peer relationships.- Specified by:
clearPeersin interfacePeer
-
deafen
public void deafen()
Description copied from interface:PeerMakes this peer deaf to any updateFromPeer calls made by notifyPeers
-
getActionContextNode
public Element getActionContextNode()
-
getDispatcherType
public abstract java.lang.String getDispatcherType()
-
getEventContext
public java.lang.String getEventContext()
-
getEventContextObj
public Obj getEventContextObj()
-
getEventID
public int getEventID()
-
getEventManager
public EventManager getEventManager()
-
getListenToDescendents
public boolean getListenToDescendents()
-
getOccurring
public boolean getOccurring()
-
getParameter
public java.lang.String getParameter(int nParam)
-
getPeer
public Peer getPeer(int nPeer)
return the requested peer
-
getRecurring
public boolean getRecurring()
-
isDeaf
public boolean isDeaf()
Description copied from interface:PeerChecks if this peer is deaf.
-
isMute
public boolean isMute()
Description copied from interface:PeerChecks if this peer is mute.
-
mute
public void mute()
Description copied from interface:PeerMakes this peer no longer notify its peers when notifyPeers is called
-
notifyPeers
public void notifyPeers(int eventType, java.lang.String arg1, java.lang.Object arg2)Description copied from interface:PeerSends notification to the peer nodes that this object has changed.- Specified by:
notifyPeersin interfacePeer- Parameters:
eventType- the event type as enumerated in this classarg1- additional event informationarg2- additional event information
-
peerRemoved
public void peerRemoved(Peer peer)
Description copied from interface:PeerCalled when this Peer is removed frompeer. Derived classes can override this method to receive direct notifications when a peer is removed.- Specified by:
peerRemovedin interfacePeer- Parameters:
peer- the Peer from which this Peer has been removed from notification.
-
removePeer
public void removePeer(Peer oPeerNode)
Remove a peer node from the notification list.- Specified by:
removePeerin interfacePeer- Parameters:
oPeerNode- - The reference to the peer object to be removed.
-
removePeeredNode
public void removePeeredNode(Peer poPeer)
- Specified by:
removePeeredNodein interfacePeer
-
setEventContextObj
public void setEventContextObj(Obj poObject)
-
setEventManager
public void setEventManager(EventManager poEventManager)
-
setListenToDescendents
public void setListenToDescendents(boolean bListenToDescendents)
-
setOccurring
public void setOccurring(boolean bOccurring)
-
setRecurring
public void setRecurring(boolean bRecurring)
-
unDeafen
public void unDeafen()
Description copied from interface:PeerAllows this peer to receive updateFromPeer calls
-
unMute
public void unMute()
Description copied from interface:PeerAllows this peer to notify its peers when notifyPeers is called.
-
updateFromPeer
public void updateFromPeer(java.lang.Object oPeerNode, int eventType, java.lang.String arg1, java.lang.Object arg2)Description copied from interface:PeerThis method will be called by the peer whenever its state changes.eventType (String)arg1 (Object)arg2 UPDATED update type (optional) ATTR_CHANGED attr name (optional) CHILD_ADDED (optional) added node CHILD_REMOVED (optional) removed node VALUE_CHANGED new data (optional) PARENT_CHANGED (optional) new parent DESCENDENT_ATTR_CHANGED attr name changed node DESCENDENT_VALUE_CHANGED (optional) changed node DESCENDENT_ADDED (optional) added node DESCENDENT_REMOVED (optional) removed node PERMS_LOCK_SET (optional) (optional) PERMS_LOCK_CLEARED (optional) (optional) PROTO_ATTR_CHANGED attr name changed node PROTO_CHILD_ADDED (optional) added node of the protoype PROTO_CHILD_REMOVED (optional) removed node from the prototype PROTO_VALUE_CHANGED new data prototype node PROTO_DESCENDENT_ATTR_CHANGED attr name changed prototype node PROTO_DESCENDENT_VALUE_CHANGED (optional) changed prototype node PROTO_DESCENDENT_ADDED (optional) added node to the prototype PROTO_DESCENDENT_REMOVED (optional) removed node from the prototype
- Specified by:
updateFromPeerin interfacePeer- Parameters:
oPeerNode- the peer to this object.eventType- the event type as enumerated in this classarg1- additional event informationarg2- additional event information
-
-