javax.slee.management
Interface NotificationSource

All Superinterfaces:
java.lang.Comparable, java.io.Serializable
All Known Implementing Classes:
ProfileTableNotification, ResourceAdaptorEntityNotification, SbbNotification, SubsystemNotification

public interface NotificationSource
extends java.lang.Comparable, java.io.Serializable

The NotificationSource interface is a marker interface that is used to identify the source of an alarm, trace, or usage notification generated within the SLEE and delivered to notification listeners.

Since:
SLEE 1.1
See Also:
AlarmNotification, TraceNotification, UsageNotification

Method Summary
 int compareTo(java.lang.Object obj)
          Compare this notification source with the specified object for order.
 boolean equals(java.lang.Object obj)
          Compare this notification source object for equality with another object.
 java.lang.String getAlarmNotificationType()
          Get the JMX notification type of alarm notifications generated in response to this notification source interacting with the Alarm Facility.
 java.lang.String getTraceNotificationType()
          Get the JMX notification type of trace notifications generated in response to this notification source interacting with the Trace Facility.
 java.lang.String getUsageNotificationType()
          Get the JMX notification type of usage notifications generated in response to this notification source interacting with its usage parameters.
 int hashCode()
          Get a hash code value for this notification source.
 java.lang.String toString()
          Get a string representation for this notification source.
 

Method Detail

getAlarmNotificationType

java.lang.String getAlarmNotificationType()
Get the JMX notification type of alarm notifications generated in response to this notification source interacting with the Alarm Facility.

Returns:
the JMX notification type

getTraceNotificationType

java.lang.String getTraceNotificationType()
Get the JMX notification type of trace notifications generated in response to this notification source interacting with the Trace Facility.

Returns:
the JMX notification type, or null if this notification source has no defined trace notification type (as it does not interact with the Trace Facility).

getUsageNotificationType

java.lang.String getUsageNotificationType()
Get the JMX notification type of usage notifications generated in response to this notification source interacting with its usage parameters.

Returns:
the JMX notification type, or null if this notification source has no defined usage notification type (as it does not interact with usage parameters).

equals

boolean equals(java.lang.Object obj)
Compare this notification source object for equality with another object.

Overrides:
equals in class java.lang.Object
Parameters:
obj - the object to compare this with.
Returns:
true if obj is a notification source object of the same type and identity as this, false otherwise.
See Also:
Object.equals(Object)

hashCode

int hashCode()
Get a hash code value for this notification source.

Overrides:
hashCode in class java.lang.Object
Returns:
a hash code value for this notification source.
See Also:
Object.hashCode()

toString

java.lang.String toString()
Get a string representation for this notification source.

Overrides:
toString in class java.lang.Object
Returns:
a string representation for this notification source.
See Also:
Object.toString()

compareTo

int compareTo(java.lang.Object obj)
Compare this notification source with the specified object for order. Returns a negative integer, zero, or a positive integer if this object is less than, equal to, or greater than the specified object.

The general contract of this method for all NotificationSource objects is that if this and obj are of the same class type, this method will compare their respective encapsulated identities. Otherwise, if the objects are of different types, the result of comparing the class names of this and obj is returned. This allows NotificationSource objects of different types to be stored in a single ordered collection.

It is illegal to pass an object that does not implement the NotificationSource interface as an argument to this method. Doing so will raise a ClassCastException.

Specified by:
compareTo in interface java.lang.Comparable
Parameters:
obj - the object to compare this with. This object must implement the NotificationSource interface.
Returns:
a negative integer, zero, or a positive integer if this notification source is considered less than, equal to, or greater than the specified object.
Throws:
java.lang.ClassCastException - if obj does not implement the NotificationSource interface.
See Also:
Comparable.compareTo(Object)


Copyright © 2008. All Rights Reserved.