public class NotificationRequestMessage extends Object implements Message
Message that requests received notifications.
This message represents the fetch-notifications
protocol operation described in the JMX Remote API specification.
It is sent from a client to a server to solicit a NotificationResponseMessage. The server need not reply
immediately if it does not have notifications that match the
client's criteria.
| Constructor and Description |
|---|
NotificationRequestMessage(long clientSequenceNumber,
int maxNotifications,
long timeout)
Constructs a
NotificationRequestMessage object. |
| Modifier and Type | Method and Description |
|---|---|
long |
getClientSequenceNumber()
Returns the client sequence number.
|
int |
getMaxNotifications()
Returns the maximum number of notifications requested.
|
long |
getTimeout()
Returns the maximum time to wait for notifications.
|
public NotificationRequestMessage(long clientSequenceNumber,
int maxNotifications,
long timeout)
Constructs a NotificationRequestMessage object.
The behavior is unspecified if any of the parameters is
negative.
clientSequenceNumber - the first sequence number that the
client is interested in. If negative, it is interpreted as
meaning the sequence number that the next notification will
have.maxNotifications - the maximum number of different
notifications to return. The TargetedNotification
array in the NotificationResponseMessage can have
more elements than this if the same notification appears more
than once.timeout - the maximum time in milliseconds to wait for a
notification to arrive. This can be 0 to indicate that the
method should not wait if there are no notifications, but
should return at once. It can be Long.MAX_VALUE
to indicate that there is no timeout.public long getClientSequenceNumber()
public int getMaxNotifications()
public long getTimeout()
Copyright © 2019 Terracotta, Inc.. All rights reserved.