com.sun.messaging.jms.notification
public class ConsumerEvent extends Event
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CONSUMER_NOT_READY
No consumer event code
|
static java.lang.String |
CONSUMER_READY
Consumer ready event code
|
Constructor and Description |
---|
ConsumerEvent(Destination dest,
Connection conn,
java.lang.String evCode,
java.lang.String evMessage)
Construct a MQ consumer event.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getBrokerAddress()
Get the broker's address that sent the event.
|
Connection |
getConnection()
Get the connection on which the event was received.
|
Destination |
getDestination()
Get the registered destination on which the event was occurred.
|
getEventCode, getEventMessage, toString
public static final java.lang.String CONSUMER_READY
public static final java.lang.String CONSUMER_NOT_READY
public ConsumerEvent(Destination dest, Connection conn, java.lang.String evCode, java.lang.String evMessage)
dest
is the Destination
object that was passed in
Connection.setConsumerEventListener(com.sun.messaging.Destination, com.sun.messaging.jms.notification.EventListener)
and is what will be returned by getDestination()
conn
is the Connection
on which this event was received and is what will be returned by
getConnection()
evCode
is what will be returned by
Event.getEventCode()
which can be either
CONSUMER_READY
or CONSUMER_NOT_READY
evMessage
is a description of the evCode
and is what will be returned by Event.getEventMessage()
dest
- the destination on which the event occurred.conn
- the connection on which the event was receivedevCode
- the event code that represents this event object.evMessage
- the event message that describes this event object.public Connection getConnection()
public java.lang.String getBrokerAddress()
public Destination getDestination()
Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.