BEA Systems, Inc.

weblogic.management.timer
Class Timer

java.lang.Object
  extended by javax.management.NotificationBroadcasterSupport
      extended by javax.management.timer.Timer
          extended by weblogic.management.timer.Timer
All Implemented Interfaces:
Serializable, MBeanRegistration, NotificationBroadcaster, NotificationEmitter, TimerMBean

public final class Timer
extends Timer
implements TimerMBean, NotificationBroadcaster, Serializable

Timer: an implementation of the JMX javax.management.TimerMBean interface that uses weblogic execute threads and honors user identity.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.management.timer.Timer
ONE_DAY, ONE_HOUR, ONE_MINUTE, ONE_SECOND, ONE_WEEK
 
Constructor Summary
Timer()
          Constructor for the Timer object
 
Method Summary
 Integer addNotification(String type, String message, Object userData, Date date)
          Adds a feature to the Notification attribute of the Timer object
 Integer addNotification(String type, String message, Object userData, Date date, long period)
          Adds a feature to the Notification attribute of the Timer object
 Integer addNotification(String type, String message, Object userData, Date date, long period, long nbOccurences)
          Adds a feature to the Notification attribute of the Timer object
 Integer addNotification(String type, String message, Object userData, Date date, long period, long nbOccurences, boolean fixedRate)
          Adds a feature to the Notification attribute of the Timer object
 void addNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback)
          Adds a feature to the NotificationListener attribute of the Timer object
 void deliverNotifications(Notification tn)
          Description of the Method
 Vector getAllNotificationIDs()
          Gets the allNotificationIDs attribute of the Timer object
 Date getDate(Integer id)
          Gets the date attribute of the Timer object
 Boolean getFixedRate(Integer id)
          Gets the fixedRate attribute of the Timer object
 int getNbNotifications()
          Gets the nbNotifications attribute of the Timer object
 Long getNbOccurences(Integer id)
          Gets the nbOccurences attribute of the Timer object
 Vector getNotificationIDs(String type)
          Gets the notificationIDs attribute of the Timer object
 MBeanNotificationInfo[] getNotificationInfo()
          Gets the notificationInfo attribute of the Timer object
 String getNotificationMessage(Integer id)
          Gets the notificationMessage attribute of the Timer object
 String getNotificationType(Integer id)
          Gets the notificationType attribute of the Timer object
 Object getNotificationUserData(Integer id)
          Gets the notificationUserData attribute of the Timer object
 Long getPeriod(Integer id)
          Gets the period attribute of the Timer object
 boolean getSendPastNotifications()
          Gets the sendPastNotifications attribute of the Timer object
 boolean isActive()
          Gets the active attribute of the Timer object
 boolean isEmpty()
          Gets the empty attribute of the Timer object
 void removeAllNotifications()
          Description of the Method
 void removeNotification(Integer id)
          Description of the Method
 void removeNotificationListener(NotificationListener listener)
          Description of the Method
 void removeNotifications(String type)
          Description of the Method
 void setSendPastNotifications(boolean value)
          Sets the sendPastNotifications attribute of the Timer object
 void start()
          Starts the timer.
 void stop()
          Stops the timer
 
Methods inherited from class javax.management.timer.Timer
postDeregister, postRegister, preDeregister, preRegister
 
Methods inherited from class javax.management.NotificationBroadcasterSupport
handleNotification, removeNotificationListener, sendNotification
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Timer

public Timer()
Constructor for the Timer object

Method Detail

getNbNotifications

public int getNbNotifications()
Gets the nbNotifications attribute of the Timer object

Specified by:
getNbNotifications in interface TimerMBean
Overrides:
getNbNotifications in class Timer
Returns:
The nbNotifications value

getAllNotificationIDs

public Vector getAllNotificationIDs()
Gets the allNotificationIDs attribute of the Timer object

Specified by:
getAllNotificationIDs in interface TimerMBean
Overrides:
getAllNotificationIDs in class Timer
Returns:
The allNotificationIDs value

getNotificationIDs

public Vector getNotificationIDs(String type)
Gets the notificationIDs attribute of the Timer object

Specified by:
getNotificationIDs in interface TimerMBean
Overrides:
getNotificationIDs in class Timer
Parameters:
type - Description of the Parameter
Returns:
The notificationIDs value

getNotificationType

public String getNotificationType(Integer id)
Gets the notificationType attribute of the Timer object

Specified by:
getNotificationType in interface TimerMBean
Overrides:
getNotificationType in class Timer
Parameters:
id - Description of the Parameter
Returns:
The notificationType value

getNotificationMessage

public String getNotificationMessage(Integer id)
Gets the notificationMessage attribute of the Timer object

Specified by:
getNotificationMessage in interface TimerMBean
Overrides:
getNotificationMessage in class Timer
Parameters:
id - Description of the Parameter
Returns:
The notificationMessage value

getNotificationUserData

public Object getNotificationUserData(Integer id)
Gets the notificationUserData attribute of the Timer object

Specified by:
getNotificationUserData in interface TimerMBean
Overrides:
getNotificationUserData in class Timer
Parameters:
id - Description of the Parameter
Returns:
The notificationUserData value

getDate

public Date getDate(Integer id)
Gets the date attribute of the Timer object

Specified by:
getDate in interface TimerMBean
Overrides:
getDate in class Timer
Parameters:
id - Description of the Parameter
Returns:
The date value

getPeriod

public Long getPeriod(Integer id)
Gets the period attribute of the Timer object

Specified by:
getPeriod in interface TimerMBean
Overrides:
getPeriod in class Timer
Parameters:
id - Description of the Parameter
Returns:
The period value

getNbOccurences

public Long getNbOccurences(Integer id)
Gets the nbOccurences attribute of the Timer object

Specified by:
getNbOccurences in interface TimerMBean
Overrides:
getNbOccurences in class Timer
Parameters:
id - Description of the Parameter
Returns:
The nbOccurences value

getFixedRate

public Boolean getFixedRate(Integer id)
Gets the fixedRate attribute of the Timer object

Specified by:
getFixedRate in interface TimerMBean
Overrides:
getFixedRate in class Timer
Parameters:
id - Notification ID
Returns:
The fixedRate attribute value

getSendPastNotifications

public boolean getSendPastNotifications()
Gets the sendPastNotifications attribute of the Timer object

Specified by:
getSendPastNotifications in interface TimerMBean
Overrides:
getSendPastNotifications in class Timer
Returns:
The sendPastNotifications value

isActive

public boolean isActive()
Gets the active attribute of the Timer object

Specified by:
isActive in interface TimerMBean
Overrides:
isActive in class Timer
Returns:
The active value

isEmpty

public boolean isEmpty()
Gets the empty attribute of the Timer object

Specified by:
isEmpty in interface TimerMBean
Overrides:
isEmpty in class Timer
Returns:
The empty value

getNotificationInfo

public MBeanNotificationInfo[] getNotificationInfo()
Gets the notificationInfo attribute of the Timer object

Specified by:
getNotificationInfo in interface NotificationBroadcaster
Overrides:
getNotificationInfo in class Timer
Returns:
The notificationInfo value

setSendPastNotifications

public void setSendPastNotifications(boolean value)
Sets the sendPastNotifications attribute of the Timer object

Specified by:
setSendPastNotifications in interface TimerMBean
Overrides:
setSendPastNotifications in class Timer
Parameters:
value - The new sendPastNotifications value

start

public void start()
Starts the timer.

Specified by:
start in interface TimerMBean
Overrides:
start in class Timer

stop

public void stop()
Stops the timer

Specified by:
stop in interface TimerMBean
Overrides:
stop in class Timer

addNotification

public Integer addNotification(String type,
                               String message,
                               Object userData,
                               Date date,
                               long period,
                               long nbOccurences)
                        throws IllegalArgumentException
Adds a feature to the Notification attribute of the Timer object

Specified by:
addNotification in interface TimerMBean
Overrides:
addNotification in class Timer
Parameters:
type - The feature to be added to the Notification attribute
message - The feature to be added to the Notification attribute
userData - The feature to be added to the Notification attribute
date - The feature to be added to the Notification attribute
period - The feature to be added to the Notification attribute
nbOccurences - The feature to be added to the Notification attribute
Returns:
Description of the Return Value
Throws:
IllegalArgumentException - Description of the Exception

addNotification

public Integer addNotification(String type,
                               String message,
                               Object userData,
                               Date date,
                               long period,
                               long nbOccurences,
                               boolean fixedRate)
                        throws IllegalArgumentException
Adds a feature to the Notification attribute of the Timer object

Specified by:
addNotification in interface TimerMBean
Overrides:
addNotification in class Timer
Parameters:
type - The feature to be added to the Notification attribute
message - The feature to be added to the Notification attribute
userData - The feature to be added to the Notification attribute
date - The feature to be added to the Notification attribute
period - The feature to be added to the Notification attribute
nbOccurences - The feature to be added to the Notification attribute
fixedRate - The value is used to determine execution scheme.
Returns:
Description of the Return Value
Throws:
IllegalArgumentException - Description of the Exception

addNotification

public Integer addNotification(String type,
                               String message,
                               Object userData,
                               Date date,
                               long period)
                        throws IllegalArgumentException
Adds a feature to the Notification attribute of the Timer object

Specified by:
addNotification in interface TimerMBean
Overrides:
addNotification in class Timer
Parameters:
type - The feature to be added to the Notification attribute
message - The feature to be added to the Notification attribute
userData - The feature to be added to the Notification attribute
date - The feature to be added to the Notification attribute
period - The feature to be added to the Notification attribute
Returns:
Description of the Return Value
Throws:
IllegalArgumentException - Description of the Exception

addNotification

public Integer addNotification(String type,
                               String message,
                               Object userData,
                               Date date)
                        throws IllegalArgumentException
Adds a feature to the Notification attribute of the Timer object

Specified by:
addNotification in interface TimerMBean
Overrides:
addNotification in class Timer
Parameters:
type - The feature to be added to the Notification attribute
message - The feature to be added to the Notification attribute
userData - The feature to be added to the Notification attribute
date - The feature to be added to the Notification attribute
Returns:
Description of the Return Value
Throws:
IllegalArgumentException - Description of the Exception

removeNotification

public void removeNotification(Integer id)
                        throws InstanceNotFoundException
Description of the Method

Specified by:
removeNotification in interface TimerMBean
Overrides:
removeNotification in class Timer
Parameters:
id - Description of the Parameter
Throws:
InstanceNotFoundException - Description of the Exception

removeNotifications

public void removeNotifications(String type)
                         throws InstanceNotFoundException
Description of the Method

Specified by:
removeNotifications in interface TimerMBean
Overrides:
removeNotifications in class Timer
Parameters:
type - Description of the Parameter
Throws:
InstanceNotFoundException - Description of the Exception

removeAllNotifications

public void removeAllNotifications()
Description of the Method

Specified by:
removeAllNotifications in interface TimerMBean
Overrides:
removeAllNotifications in class Timer

addNotificationListener

public void addNotificationListener(NotificationListener listener,
                                    NotificationFilter filter,
                                    Object handback)
                             throws IllegalArgumentException
Adds a feature to the NotificationListener attribute of the Timer object

Specified by:
addNotificationListener in interface NotificationBroadcaster
Overrides:
addNotificationListener in class NotificationBroadcasterSupport
Parameters:
listener - The feature to be added to the NotificationListener attribute
filter - The feature to be added to the NotificationListener attribute
handback - The feature to be added to the NotificationListener attribute
Throws:
IllegalArgumentException - Description of the Exception

removeNotificationListener

public void removeNotificationListener(NotificationListener listener)
                                throws ListenerNotFoundException
Description of the Method

Specified by:
removeNotificationListener in interface NotificationBroadcaster
Overrides:
removeNotificationListener in class NotificationBroadcasterSupport
Parameters:
listener - Description of the Parameter
Throws:
ListenerNotFoundException - Description of the Exception

deliverNotifications

public void deliverNotifications(Notification tn)
Description of the Method

Parameters:
tn - Description of the Parameter

Documentation is available at
http://download.oracle.com/docs/cd/E13222_01/wls/docs100
Copyright 2006 BEA Systems Inc.