All Implemented Interfaces:
HealthCenterData, LockingData, NotificationBroadcaster, NotificationEmitter

public class LockingDataImpl extends HealthCenterDataImpl implements LockingData
  • Constructor Details

    • LockingDataImpl

      public LockingDataImpl(com.ibm.java.diagnostics.common.datamodel.data.Data data)
  • Method Details

    • getRecommendationLabel

      protected String getRecommendationLabel()
      Specified by:
      getRecommendationLabel in class HealthCenterDataImpl
    • getSubsystemLabel

      protected String getSubsystemLabel()
      Specified by:
      getSubsystemLabel in class HealthCenterDataImpl
    • getInflatedJavaMonitors

      public MonitorData[] getInflatedJavaMonitors()
      Description copied from interface: LockingData
      Gets an array of MonitorData objects representing locks taken by the application that is being monitored. NOTE If running in "event only" mode, this data will always return an empty array. This is because "event only" does not store any data to inquire on. Instead, you need to use the api calls to register listeners and get notification of when events occur
      Specified by:
      getInflatedJavaMonitors in interface LockingData
      Returns:
      an array of MonitorData objects.
    • getInflatedSystemMonitors

      public MonitorData[] getInflatedSystemMonitors()
      Description copied from interface: LockingData
      Gets an array of MonitorData objects representing locks taken by the Java runtime environment. NOTE If running in "event only" mode, this data will always return an empty array. This is because "event only" does not store any data to inquire on. Instead, you need to use the api calls to register listeners and get notification of when events occur
      Specified by:
      getInflatedSystemMonitors in interface LockingData
      Returns:
      an array of MonitorData objects.
    • startNotifying

      public void startNotifying()
      Description copied from interface: HealthCenterData
      Starts a thread which checks for changes in the data every 2000 milliseconds and sends notifications if an update has occurred. To handle these notifications, a NotificationListener needs to be added to the object the thread is being started from.
      Specified by:
      startNotifying in interface HealthCenterData
    • startNotifying

      public void startNotifying(long delay)
      Description copied from interface: HealthCenterData
      Starts a thread which checks for changes in the data and sends notifications if an update has occurred. To handle these notifications, a NotificationListener needs to be added to the object the thread is being started from.
      Specified by:
      startNotifying in interface HealthCenterData
      Parameters:
      delay - The number of milliseconds between each update. The default is 2000 milliseconds and anything below this will not be accepted.
    • addLockingListener

      public void addLockingListener(LockingEventListener listener)
      Description copied from interface: LockingData
      Add a listener for notification of when a locking event occurs
      Specified by:
      addLockingListener in interface LockingData
    • removeLockingListener

      public void removeLockingListener(LockingEventListener listener)
      Description copied from interface: LockingData
      Remove one of registered listeners.
      Specified by:
      removeLockingListener in interface LockingData