Overview | Package | Class | Use | Tree | Serialized | Deprecated | Index | Help
| 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

## com.ibm.conversation
Interface ConversationPolicyHandlerFactory

All Known Implementing Classes:
  AbleConversationPolicyHandlerFactory

public interface ConversationPolicyHandlerFactory

The ConversationPolicyHandlerFactory interface is responsible for creation and initialization of ConversationPolicyHandlers.

Each ConversationManager has a ConversationPolicyHandlerFactory, which it assigns to each new Conversation when it creates it.

Method Summary
`ConversationPolicyHandler` | `getPolicyHandler(java.lang.String cpName, java.lang.String selfRole)` Creates and returns a new ConversationPolicyHandler initialized with the given conversation policy and role.
`java.util.Set` | `getPolicyNames()` Returns the names of the policies this factory is able to create.
`java.util.Collection` | `getRoles(java.lang.String policyName)` Returns the roles defined by the given conversation policy.
`boolean` | `isPolicySupported(java.lang.String cpName, java.lang.String selfRole)` Indicates whether the given policy and role is supported.

Method Detail

### getPolicyNames

    public java.util.Set getPolicyNames()

  Returns the names of the policies this factory is able to create.

  Returns:
    The Set of policy names.

### getRoles

    public java.util.Collection getRoles(java.lang.String policyName)

  Returns the roles defined by the given conversation policy.

  Parameters:
    `policyName` - The name of the conversation policy.
  Returns:
    A Collection containing the roles, or `null` if the policyName was not found.

### isPolicySupported

    public boolean isPolicySupported(java.lang.String cpName,
                                     java.lang.String selfRole)

  Indicates whether the given policy and role is supported. This is equivalent to whether a ConversationPolicyHandler for the given policy & role can be created.

  Returns:
    true if the policy/role is supported, false if not.

### getPolicyHandler

    public ConversationPolicyHandler getPolicyHandler(java.lang.String cpName,
                                                      java.lang.String selfRole)

  Creates and returns a new ConversationPolicyHandler initialized with the given conversation policy and role.

  If there is no known policy with the given name, or if the role does not match one of the roles defined in the policy, returns `null`.

  Parameters:
    `cpName` - The name of the conversation policy to be used.
    `selfRole` - The role to play in the conversation policy.
  Returns:
    The new ConversationPolicyHandler, or `null` if creation failed.

Overview | Package | Class | Use | Tree | Serialized | Deprecated | Index | Help
| 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

(C) Copyright IBM Corporation 1999, 2005