public class JoltUserEvent
extends java.lang.Object
JoltSession
,
JoltMessage
,
JoltReply
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
UNSOLMSG
The regular expression constant to request unsolicited messages.
|
Constructor and Description |
---|
JoltUserEvent(java.lang.String expr,
java.lang.String filter,
Session session)
This constructor subscribes the specific asynchronous notification.
|
Modifier and Type | Method and Description |
---|---|
int |
unsubscribe()
This method unsubscribes this event.
|
static int |
unsubscribeAll(Session session)
Unsubscribe all event subscriptions in the specified session.
|
public static final java.lang.String UNSOLMSG
public JoltUserEvent(java.lang.String expr, java.lang.String filter, Session session) throws EventException, SessionException
expr
- A string containing a regular expression in the same
format as the event expression used in tpsubscribe(). The maximum
length of this parameter is 255 characters. Setting this parameter
to the constant JoltUserEvent.UNSOLMSG allows the client to receive
unsolicited messages (generated as a result of tpnotify() or
tpbroadcast()).filter
- Null or Boolean expression. This parameter is a
string in the same format as the filter parameter passed
to tpsubscribe(). The maximum length of this parameter is
255 characters. Filter rules are specific to the buffers to which
they are applied. Refer to Tuxedo documentation for a complete
explanation of the filtering function. Filtering is done on the
Tuxedo server, not the Jolt client.session
- A JoltSession object, the Jolt session
to which the subscription is bound. An event is bound to a
a single session.SessionException
- Invalid session or a session error.EventException
- Indicates that the filter for
unsolicited subscription is not null, or event subscription failed.public int unsubscribe() throws EventException, SessionException
EventException
- No such event or invalid event.SessionException
- An error occurs in this session.public static int unsubscribeAll(Session session) throws EventException, SessionException
session
- a Jolt session object.SessionException
- Invalid session or a session error.EventException
- Unsubscription error from Tuxedo.