Class ConversationImpl
java.lang.Object
org.jboss.weld.contexts.conversation.ConversationImpl
- All Implemented Interfaces:
jakarta.enterprise.context.Conversation,Serializable,ManagedConversation
- Author:
- Nicklas Karlsson, Marko Luksa
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidbegin()voidvoidend()getId()longGets the last time the conversation was used (for data access)longbooleanbooleanbooleanlock(long timeout) Attempts to lock the conversation for exclusive usagevoidsetTimeout(long timeout) toString()voidtouch()Touches the managed conversation, updating the "last used" timestampbooleanunlock()Attempts to unlock the conversation
-
Constructor Details
-
ConversationImpl
-
-
Method Details
-
begin
public void begin()- Specified by:
beginin interfacejakarta.enterprise.context.Conversation
-
begin
- Specified by:
beginin interfacejakarta.enterprise.context.Conversation
-
end
public void end()- Specified by:
endin interfacejakarta.enterprise.context.Conversation
-
getId
- Specified by:
getIdin interfacejakarta.enterprise.context.Conversation
-
getTimeout
public long getTimeout()- Specified by:
getTimeoutin interfacejakarta.enterprise.context.Conversation
-
setTimeout
public void setTimeout(long timeout) - Specified by:
setTimeoutin interfacejakarta.enterprise.context.Conversation
-
toString
-
isTransient
public boolean isTransient()- Specified by:
isTransientin interfacejakarta.enterprise.context.Conversation
-
getLastUsed
public long getLastUsed()Description copied from interface:ManagedConversationGets the last time the conversation was used (for data access)- Specified by:
getLastUsedin interfaceManagedConversation- Returns:
- time (in ms) since the conversation was last used
-
touch
public void touch()Description copied from interface:ManagedConversationTouches the managed conversation, updating the "last used" timestamp- Specified by:
touchin interfaceManagedConversation
-
lock
public boolean lock(long timeout) Description copied from interface:ManagedConversationAttempts to lock the conversation for exclusive usage- Specified by:
lockin interfaceManagedConversation- Parameters:
timeout- The time in milliseconds to wait on the lock- Returns:
- True if lock was successful, false otherwise
-
unlock
public boolean unlock()Description copied from interface:ManagedConversationAttempts to unlock the conversation- Specified by:
unlockin interfaceManagedConversation- Returns:
- true if the unlock was successful, false otherwise
-
isContextActive
public boolean isContextActive()
-