|
Errai 3.0.1-SNAPSHOT | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jboss.errai.cdi.server.events.EventConversationContext
public class EventConversationContext
An context control helper for handling Errai conversations within CDI. Internally, this class uses a
ThreadLocal
to store its state. Thus, conversational scopes within Errai are dependent upon single-threaded
dispatch within the CDI container.
Nested Class Summary | |
---|---|
static class |
EventConversationContext.Context
|
Constructor Summary | |
---|---|
EventConversationContext()
|
Method Summary | |
---|---|
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. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public EventConversationContext()
Method Detail |
---|
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 instance
|
Errai 3.0.1-SNAPSHOT | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |