Package oracle.jdbc.aq
Class AQNotificationEvent
- java.lang.Object
-
- java.util.EventObject
-
- oracle.jdbc.aq.AQNotificationEvent
-
- All Implemented Interfaces:
java.io.Serializable
public abstract class AQNotificationEvent extends java.util.EventObjectAn AQNotificationEvent will be created whenever a new message is enqueued in a queue for which you have registered your interest (see OracleConnection.registerAQNotification).The AQNotificationEvent provides information about the new message that has been enqueued.
- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classAQNotificationEvent.AdditionalEventTypestatic classAQNotificationEvent.EventType
-
Constructor Summary
Constructors Modifier Constructor Description protectedAQNotificationEvent(java.lang.Object source)
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description abstract AQNotificationEvent.AdditionalEventTypegetAdditionalEventType()Retrieve the additional event type.abstract java.lang.StringgetConnectionInformation()Retrieves a description of the TCP connection on which the notification was received.abstract java.lang.StringgetConsumerName()Retrieves the name of the consumer.abstract AQNotificationEvent.EventTypegetEventType()Retrieve the event type.abstract byte[]getMessageId()Retrieves the ID of the new message.abstract AQMessagePropertiesgetMessageProperties()Retrieves the properties of the new message.abstract byte[]getPayload()Retrieves the payload of the new message.abstract java.lang.StringgetQueueName()Retrieves the name of the queue.abstract java.lang.StringgetRegistration()Retrieves the registration name which is the name that you provided when you registered for AQ notification with theregisterAQNotificationmethod.abstract java.lang.StringtoString()
-
-
-
Method Detail
-
getMessageProperties
public abstract AQMessageProperties getMessageProperties() throws java.sql.SQLException
Retrieves the properties of the new message.- Throws:
java.sql.SQLException
-
getRegistration
public abstract java.lang.String getRegistration() throws java.sql.SQLExceptionRetrieves the registration name which is the name that you provided when you registered for AQ notification with theregisterAQNotificationmethod.In the case of a single consumer queue, the registration name is the name of the queue whereas in the case of a multi-consumer queue, it's the name of the queue plus the name of the consumer ("SCOTT.MY_QUEUE:RECEIVER").
- Throws:
java.sql.SQLException
-
getPayload
public abstract byte[] getPayload() throws java.sql.SQLExceptionRetrieves the payload of the new message. Note that this feature only works with RAW queues and that it needs to be activated with the OracleConnection.NTF_AQ_PAYLOAD option during registration.- Throws:
java.sql.SQLException
-
getQueueName
public abstract java.lang.String getQueueName() throws java.sql.SQLExceptionRetrieves the name of the queue.- Throws:
java.sql.SQLException
-
getMessageId
public abstract byte[] getMessageId() throws java.sql.SQLExceptionRetrieves the ID of the new message.- Throws:
java.sql.SQLException
-
getConsumerName
public abstract java.lang.String getConsumerName() throws java.sql.SQLExceptionRetrieves the name of the consumer. In the case of a multi-consumer queue, this retrieves the name of the consumer upon which you register for AQ notification.- Throws:
java.sql.SQLException
-
getConnectionInformation
public abstract java.lang.String getConnectionInformation()
Retrieves a description of the TCP connection on which the notification was received.
-
getEventType
public abstract AQNotificationEvent.EventType getEventType()
Retrieve the event type.
-
getAdditionalEventType
public abstract AQNotificationEvent.AdditionalEventType getAdditionalEventType()
Retrieve the additional event type.
-
toString
public abstract java.lang.String toString()
- Overrides:
toStringin classjava.util.EventObject
-
-