|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.util.EventObject
javax.management.Notification
javax.management.AttributeChangeNotification
public class AttributeChangeNotification
Defines the notification used to let listeners know of
an attribute change. The bean itself is responsible
for creating and transmitting the notification when the
attribute changes, by implementing
NotificationBroadcaster
. For example, if a
bean increments the integer, count
, it
should send a notification with the
attributeName
, "count"
,
the attributeType
, "Integer"
and the old and new values of the attribute.
Field Summary | |
---|---|
static String |
ATTRIBUTE_CHANGE
The attribute type for attribute change notifications. |
Fields inherited from class javax.management.Notification |
---|
source |
Constructor Summary | |
---|---|
AttributeChangeNotification(Object source,
long sequenceNumber,
long timeStamp,
String msg,
String name,
String type,
Object oldVal,
Object newVal)
Constructs a new AttributeChangeNotification
with the specified source, sequence number, timestamp,
message, and the attribute name, type, old value and
new value. |
Method Summary | |
---|---|
String |
getAttributeName()
Returns the name of the attribute that changed. |
String |
getAttributeType()
Returns the type of the attribute that changed. |
Object |
getNewValue()
Returns the new value of the attribute. |
Object |
getOldValue()
Returns the old value of the attribute. |
Methods inherited from class javax.management.Notification |
---|
getMessage, getSequenceNumber, getTimeStamp, getType, getUserData, setSequenceNumber, setSource, setTimeStamp, setUserData, toString |
Methods inherited from class java.util.EventObject |
---|
getSource |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final String ATTRIBUTE_CHANGE
Constructor Detail |
---|
public AttributeChangeNotification(Object source, long sequenceNumber, long timeStamp, String msg, String name, String type, Object oldVal, Object newVal)
AttributeChangeNotification
with the specified source, sequence number, timestamp,
message, and the attribute name, type, old value and
new value.
source
- the producer of the notification, which
is usually the bean that changed the
attribute.sequenceNumber
- the sequence number of the
notification.timeStamp
- the date and time of the notification.msg
- the message content of the notification.name
- the name of the attribute.type
- the type of the attribute.oldVal
- the old value of the attribute.newVal
- the new value of the attribute.Method Detail |
---|
public String getAttributeName()
public String getAttributeType()
public Object getOldValue()
public Object getNewValue()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |