public abstract class

AbstractMonitor

extends Object
implements Monitor
java.lang.Object
   ↳ sun.jvmstat.monitor.AbstractMonitor
Known Direct Subclasses
Known Indirect Subclasses

Class Overview

The base class for Instrumentation Monitoring Objects. This base class provides implementations of the Monitor methods that are common to all classes implementing the Monitor interface..

Summary

Fields
protected String name
protected boolean supported
protected Units units
protected Variability variability
protected int vectorLength
Protected Constructors
AbstractMonitor(String name, Units units, Variability variability, boolean supported, int vectorLength)
Create a vector instrumentation monitoring object with the given name and attributes.
AbstractMonitor(String name, Units units, Variability variability, boolean supported)
Create a scalar instrumentation monitoring object with the given name and attributes.
Public Methods
String getBaseName()
Returns the base name of this instrumentation object.
String getName()
Returns the name of this instrumentation object.
Units getUnits()
Returns the Units for this instrumentation monitoring object.
abstract Object getValue()
Return an Object that encapsulates this instrumentation object's current data value.
Variability getVariability()
Returns the Variability for this instrumentation object.
int getVectorLength()
Return the length of the vector.
boolean isSupported()
Test if the instrumentation object is supported.
boolean isVector()
Test if the instrumentation object is a vector type.
[Expand]
Inherited Methods
From class java.lang.Object
From interface sun.jvmstat.monitor.Monitor

Fields

protected String name

protected boolean supported

protected Units units

protected Variability variability

protected int vectorLength

Protected Constructors

protected AbstractMonitor (String name, Units units, Variability variability, boolean supported, int vectorLength)

Create a vector instrumentation monitoring object with the given name and attributes.

Parameters
name the name to assign to this instrumentation object.
units the units of measure attribute
variability the variability attribute
supported support level indicator
vectorLength the length of the vector, or 0 if not a vector type.

protected AbstractMonitor (String name, Units units, Variability variability, boolean supported)

Create a scalar instrumentation monitoring object with the given name and attributes.

Parameters
name the name to assign to this instrumentation object.
units the units of measure attribute
variability the variability attribute
supported support level indicator

Public Methods

public String getBaseName ()

Returns the base name of this instrumentation object. The base name is the component of the name following the last "." character in the name.

Returns
  • String - the base name of the name assigned to this instrumentation monitoring object.

public String getName ()

Returns the name of this instrumentation object.

Returns
  • String - the name assigned to this instrumentation monitoring object

public Units getUnits ()

Returns the Units for this instrumentation monitoring object.

Returns
  • Units - the units of measure attribute

public abstract Object getValue ()

Return an Object that encapsulates this instrumentation object's current data value.

public Variability getVariability ()

Returns the Variability for this instrumentation object.

Returns
  • Variability - the variability attribute

public int getVectorLength ()

Return the length of the vector.

Returns
  • int - the length of the vector or zero if this instrumentation object is a scalar type.

public boolean isSupported ()

Test if the instrumentation object is supported.

public boolean isVector ()

Test if the instrumentation object is a vector type.

Returns
  • boolean - true if this instrumentation object is a vector type, false otherwise.