public class EventConversationContext extends Object
ThreadLocal
to store its state. Thus, conversational scopes within Errai are dependent upon single-threaded
dispatch within the CDI container.Modifier and Type | Class and Description |
---|---|
static class |
EventConversationContext.Context |
Constructor and Description |
---|
EventConversationContext() |
Modifier and Type | Method and Description |
---|---|
static void |
activate(Message message)
Convenience method to active the conversation scope from a Errai
Message object, by extracting the
session ID referenced within. |
static void |
activate(Object o,
QueueSession session)
Activate the conversation scope.
|
static void |
activate(QueueSession session)
Activate a conversations scope.
|
static void |
deactivate()
Deactivate any current scope.
|
static EventConversationContext.Context |
get()
Get the current scope.
|
static boolean |
isEventObjectInContext(Object event)
Checks to see if the specified event reference is the same event reference that initiated the conversation.
|
public static void activate(Object o, QueueSession session)
o
- reference to the event object which is opening the scope.session
- the bus session ID of the scope.public static void activate(QueueSession session)
session
- the bus session ID of the scope.public static void activate(Message message)
Message
object, by extracting the
session ID referenced within.message
- An Errai message.public static void deactivate()
public static EventConversationContext.Context get()
public static boolean isEventObjectInContext(Object event)
event
- the event instanceCopyright © 2013-2015 JBoss, a division of Red Hat. All Rights Reserved.