org.apache.tuscany.sca.core.conversation
Class ConversationManagerImpl

java.lang.Object
  extended by org.apache.tuscany.sca.core.conversation.ConversationManagerImpl
All Implemented Interfaces:
ConversationManager

public class ConversationManagerImpl
extends java.lang.Object
implements ConversationManager


Constructor Summary
ConversationManagerImpl()
          constructor
 
Method Summary
 void addListener(ConversationListener listener)
          Add a listener to this conversation
 void endConversation(java.lang.Object conversationID)
           
 void expireConversation(java.lang.Object conversationID)
           
 ExtendedConversation getConversation(java.lang.Object conversationID)
           
 long getMaxAge()
          returns the default max age
 long getMaxIdleTime()
          return the default max idle time
 void removeListener(ConversationListener listener)
          Remove a listener from this conversation
 void scheduleConversation(ExtendedConversationImpl aConversation, long time)
          starts the reaper thread
 ExtendedConversation startConversation(java.lang.Object conversationID)
           
 void stopReaper()
          stops the reaper thread
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConversationManagerImpl

public ConversationManagerImpl()
constructor

Method Detail

addListener

public void addListener(ConversationListener listener)
Description copied from interface: ConversationManager
Add a listener to this conversation

Specified by:
addListener in interface ConversationManager
See Also:
ConversationManager.addListener(org.apache.tuscany.sca.core.conversation.ConversationListener)

endConversation

public void endConversation(java.lang.Object conversationID)
Specified by:
endConversation in interface ConversationManager
See Also:
org.apache.tuscany.sca.core.conversation.ConversationManager#endConversation(org.apache.tuscany.sca.core.conversation.ExtendedConversation)

expireConversation

public void expireConversation(java.lang.Object conversationID)
Specified by:
expireConversation in interface ConversationManager

getConversation

public ExtendedConversation getConversation(java.lang.Object conversationID)
Specified by:
getConversation in interface ConversationManager
Returns:
See Also:
ConversationManager.getConversation(java.lang.Object)

removeListener

public void removeListener(ConversationListener listener)
Description copied from interface: ConversationManager
Remove a listener from this conversation

Specified by:
removeListener in interface ConversationManager
See Also:
ConversationManager.removeListener(org.apache.tuscany.sca.core.conversation.ConversationListener)

scheduleConversation

public void scheduleConversation(ExtendedConversationImpl aConversation,
                                 long time)
starts the reaper thread


stopReaper

public void stopReaper()
stops the reaper thread


startConversation

public ExtendedConversation startConversation(java.lang.Object conversationID)
Specified by:
startConversation in interface ConversationManager
Returns:
See Also:
ConversationManager.startConversation(java.lang.Object)

getMaxIdleTime

public long getMaxIdleTime()
return the default max idle time

Specified by:
getMaxIdleTime in interface ConversationManager
Parameters:
impProvider - the implementation Provider to extract any ConversationAttribute details
Returns:
the default max idle time for a conversation

getMaxAge

public long getMaxAge()
returns the default max age

Specified by:
getMaxAge in interface ConversationManager
Parameters:
impProvider - the implementation Provider to extract any ConversationAttribute details
Returns:
the default max age for a conversation