|
ABLE 2.3.0 07/13/2005 14:21:00 | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||
java.lang.Objectcom.ibm.able.conversation.AbleOwned
com.ibm.able.conversation.AblePlatformConversationSetupLogic
Class AblePlatformConversationSetupLogic implements the decision logic functions required for the conversation setup handshake defined in the "ConversationSetup" CP.
This class accepts all requests. Subclasses may modify this behavior by overriding
decideAcceptance.
| Constructor Summary | |
|---|---|
AblePlatformConversationSetupLogic()
Constructs an AblePlatformConversationSetupLogic object. |
|
AblePlatformConversationSetupLogic(AbleBean newOwner)
Constructs an AblePlatformConversationSetupLogic object. |
|
AblePlatformConversationSetupLogic(AbleBean newOwner,
ConversationManager mgr)
Constructs an AblePlatformConversationSetupLogic object. |
|
| Method Summary | |
|---|---|
protected void |
callerConversationAccepted(Conversation conv,
DecisionDataHandle ddh)
|
void |
conversationAccepted(Conversation conv,
DecisionDataHandle ddh)
Decision-logic callback for when the other agent has accepted this agent's request to start a conversation. |
void |
conversationOver(Conversation conv,
DecisionDataHandle ddh)
Decision-logic callback for when the conversation has ended. |
void |
conversationRequested(Conversation conv,
DecisionDataHandle ddh)
Decision-logic callback for the second pbase of conversation setup. |
boolean |
decideAcceptance(javax.agent.AgentName partnerName,
javax.agent.Locator partnerLocator,
java.lang.String proposedRootPolicy,
java.lang.String proposedAcceptorRole)
Indicates whether this agent accepts the given request for a conversation. |
ConversationManager |
getConversationManager()
Returns the ConversationManager to which this object is bound. |
java.lang.String |
getRootPartnerRole(java.lang.String convId)
Returns the partner agent's current role in the given conversation. |
java.lang.String |
getRootPolicyName(java.lang.String convId)
Returns the name of the root conversation policy in the given conversation. |
java.lang.String |
getRootSelfRole(java.lang.String convId)
Returns this agent's current role in the given conversation. |
boolean |
isPolicySupported(java.lang.String policyName,
java.lang.String selfRole)
Indicates whether this agent is able to load the given conversation policy and role. |
boolean |
isValidPartnerPolicy(java.lang.String convId,
java.lang.String policyName,
java.lang.String acceptorRole)
Indicates whether the given conversation policy and partner's role are valid--i.e., are consistent with the current settings of the conversation. |
protected void |
responderConversationAccepted(Conversation conv,
DecisionDataHandle ddh)
Helper method called when the conversation-setup messages have been properly exchanged. |
void |
setConversationManager(ConversationManager manager)
Sets the ConversationManager to which this object is bound. |
void |
setRootPolicy(java.lang.String convId,
java.lang.String policyName,
java.lang.String selfRole)
Sets the root conversation policy name and this agent's role for the given conversation. |
void |
start(Conversation conv,
DecisionDataHandle ddh)
Decision-point callback for the start of the conversation. |
| Methods inherited from class com.ibm.able.conversation.AbleOwned |
|---|
getAbleOwner, logException, logMessage, setAbleOwner |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public AblePlatformConversationSetupLogic()
public AblePlatformConversationSetupLogic(AbleBean newOwner)
newOwner - The AbleBean that owns this object.
public AblePlatformConversationSetupLogic(AbleBean newOwner,
ConversationManager mgr)
newOwner - The AbleBean that owns this object.mgr - The ConversationManager to which this object is bound.| Method Detail |
public ConversationManager getConversationManager()
public void setConversationManager(ConversationManager manager)
manager - The new ConversationManager to bind this object to.public java.lang.String getRootPartnerRole(java.lang.String convId)
convId - The ID of the conversation in question.
null if there is no conversation with the given ID..public java.lang.String getRootSelfRole(java.lang.String convId)
convId - The ID of the conversation in question.
null if there is no
conversation with the given ID.public java.lang.String getRootPolicyName(java.lang.String convId)
convId - The ID of the conversation in question.
null if there is no conversation with the given ID.
public void setRootPolicy(java.lang.String convId,
java.lang.String policyName,
java.lang.String selfRole)
convId - The ID of the conversation in question.policyName - The new root conversation policy.selfRole - The new role this agent plays in the root conversation policy.
public boolean isPolicySupported(java.lang.String policyName,
java.lang.String selfRole)
policyName - The name of the conversation policy in question.selfRole - The role this agent would play in the given conversation policy.
public boolean isValidPartnerPolicy(java.lang.String convId,
java.lang.String policyName,
java.lang.String acceptorRole)
convId - The ID of the conversation in question.policyName - The conversation policy name.acceptorRole - The name the other agent will play in the conversation.
public void start(Conversation conv,
DecisionDataHandle ddh)
conv - The Conversation to which this callback applies.ddh - The DecisionDataHandle containing inbound decision data.
public void conversationRequested(Conversation conv,
DecisionDataHandle ddh)
conv - The Conversation to which the callback applies.ddh - The DecisionDataHandle containing the inbound decision-data.
public void conversationAccepted(Conversation conv,
DecisionDataHandle ddh)
conv - The Conversation to which this callback applies.ddh - The DecisionDataHandle containing inbound decision-data.
protected void callerConversationAccepted(Conversation conv,
DecisionDataHandle ddh)
protected void responderConversationAccepted(Conversation conv,
DecisionDataHandle ddh)
conv - The Conversation to be finalized.ddh - The inbound decision-data received with the last message.
public void conversationOver(Conversation conv,
DecisionDataHandle ddh)
conv - The Conversation that is ending.ddh - Inbound decision-data received from the last inbound message.
public boolean decideAcceptance(javax.agent.AgentName partnerName,
javax.agent.Locator partnerLocator,
java.lang.String proposedRootPolicy,
java.lang.String proposedAcceptorRole)
true.
partnerName - The AgentName of the requestor agent.partnerLocator - The Locator of the requestor agent.proposedRootPolicy - The root conversation policy proposed by the
requestor agent.proposedAcceptorRole - The role this agent would be taking on in the
root conversation policy.
true.
|
ABLE 2.3.0 07/13/2005 14:21:00 | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||