|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.glassfish.cafe.api.Agent<T>
T - The type of application data in this Agent.public abstract class Agent<T>
Agent objects encapsulate application logic related to a Communication artifact like Communication, Participant etc. An instance of this class will be attached to the Communication artifacts by the application. Thus it is available during any kind of events pertaining to that artifact.
| Constructor Summary | |
|---|---|
Agent()
|
|
| Method Summary | |
|---|---|
T |
get()
Return the application specific data. |
CommunicationContext<?,?,?> |
getCommunicationContext()
Retrieve the CommunicationContext object in the Application Link. |
void |
invoke()
Invoke the the agent to perform application specific tasks. |
void |
invoke(CommunicationEvent.Type cevent)
Invoke the the agent to perform application specific tasks. |
void |
invoke(ParticipantEvent.Type pvent)
Invoke the the agent to perform application specific tasks. |
boolean |
isCallbackEnabled()
Gets the callback enabled flag. |
void |
set(T applicationData)
Set application specific data. |
void |
setCallbackEnabled(boolean callbackEnabled)
Sets the callback enabled flag. |
void |
setCommunicationContext(CommunicationContext<?,?,?> context)
Set the CommunicationContext object. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Agent()
| Method Detail |
|---|
public boolean isCallbackEnabled()
public void setCallbackEnabled(boolean callbackEnabled)
callbackEnabled - true of container has to callback.public final void setCommunicationContext(CommunicationContext<?,?,?> context)
context - An instance of CommunicationContext object.public final CommunicationContext<?,?,?> getCommunicationContext()
public void invoke()
public void invoke(CommunicationEvent.Type cevent)
public void invoke(ParticipantEvent.Type pvent)
public final void set(T applicationData)
applicationData - An Application Data object.public final T get()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||