|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.excalibur.instrument.manager.impl.InstrumentSampleDescriptorImpl
public class InstrumentSampleDescriptorImpl
Describes an InstrumentSample and acts as a Proxy to protect the original InstrumentSample object.
| Field Summary | |
|---|---|
private InstrumentSample |
m_instrumentSample
The InstrumentSample. |
| Constructor Summary | |
|---|---|
InstrumentSampleDescriptorImpl(InstrumentSample InstrumentSample)
Creates a new InstrumentSampleDescriptor. |
|
| Method Summary | |
|---|---|
void |
addInstrumentSampleListener(org.apache.excalibur.instrument.manager.InstrumentSampleListener listener)
Registers a InstrumentSampleListener with a InstrumentSample given a name. |
long |
extendLease(long lease)
Extends the lease to be lease milliseconds from the current time. |
java.lang.String |
getDescription()
Returns the description of the sample. |
org.apache.excalibur.instrument.manager.InstrumentDescriptor |
getInstrumentDescriptor()
Returns a reference to the descriptor of the Instrument of the sample. |
int |
getInstrumentType()
Returns the Type of the Instrument which can use the sample. |
long |
getInterval()
Returns the sample interval. |
long |
getLeaseExpirationTime()
Returns the time that the current lease expires. |
java.lang.String |
getName()
Returns the name of the sample. |
int |
getSize()
Returns the number of samples in the sample history. |
org.apache.excalibur.instrument.manager.InstrumentSampleSnapshot |
getSnapshot()
Obtains a static snapshot of the InstrumentSample. |
int |
getStateVersion()
Returns the stateVersion of the sample. |
long |
getTime()
Obtain the UNIX time of the beginning of the sample. |
int |
getType()
Returns the type of the Instrument Sample. |
int |
getValue()
Obtain the value of the sample. |
boolean |
isConfigured()
Returns true if the InstrumentSample was configured in the instrumentables section of the configuration. |
void |
removeInstrumentSampleListener(org.apache.excalibur.instrument.manager.InstrumentSampleListener listener)
Unregisters a InstrumentSampleListener from a InstrumentSample given a name. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private InstrumentSample m_instrumentSample
| Constructor Detail |
|---|
InstrumentSampleDescriptorImpl(InstrumentSample InstrumentSample)
InstrumentSample - InstrumentSample being described.| Method Detail |
|---|
public boolean isConfigured()
isConfigured in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorpublic java.lang.String getName()
getName in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorpublic long getInterval()
getInterval in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorpublic int getSize()
getSize in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorpublic java.lang.String getDescription()
getDescription in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorpublic int getType()
getType in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorpublic int getValue()
getValue in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorpublic long getTime()
getTime in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorpublic int getInstrumentType()
Should be one of the following: InstrumentManager.PROFILE_POINT_TYPE_COUNTER or InstrumentManager.PROFILE_POINT_TYPE_VALUE
getInstrumentType in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorpublic org.apache.excalibur.instrument.manager.InstrumentDescriptor getInstrumentDescriptor()
getInstrumentDescriptor in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorpublic void addInstrumentSampleListener(org.apache.excalibur.instrument.manager.InstrumentSampleListener listener)
addInstrumentSampleListener in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorlistener - The listener which should start receiving updates from the
InstrumentSample.public void removeInstrumentSampleListener(org.apache.excalibur.instrument.manager.InstrumentSampleListener listener)
removeInstrumentSampleListener in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorlistener - The listener which should stop receiving updates from the
InstrumentSample.public long getLeaseExpirationTime()
getLeaseExpirationTime in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorpublic long extendLease(long lease)
extendLease in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorlease - The length of the lease in milliseconds.
public org.apache.excalibur.instrument.manager.InstrumentSampleSnapshot getSnapshot()
getSnapshot in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptorpublic int getStateVersion()
getStateVersion in interface org.apache.excalibur.instrument.manager.InstrumentSampleDescriptor
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||