eu.reservoir.monitoring.core
Class ProducerMeasurement

java.lang.Object
  extended by eu.reservoir.monitoring.core.ProducerMeasurement
All Implemented Interfaces:
Measurement, ProbeMeasurement

public class ProducerMeasurement
extends java.lang.Object
implements Measurement, ProbeMeasurement

A class for measurements in producers.


Constructor Summary
ProducerMeasurement(Probe aProbe, java.util.List<ProbeValue> attrs)
          Construct a Measurement, given the Probe who sends the Measurement and a list of ProbeValues.
ProducerMeasurement(Probe aProbe, java.util.List<ProbeValue> attrs, java.lang.String theType)
          Construct a Measurement, given the Probe who sends the Measurement and a list of ProbeValues, and a type for the Measurement.
ProducerMeasurement(Probe aProbe, java.util.Map<java.lang.Integer,java.lang.Object> attrs)
          Construct a Measurement, given the Probe who sends the Measurement and a map of field number to field value.
ProducerMeasurement(Probe aProbe, java.util.Map<java.lang.Integer,java.lang.Object> attrs, java.lang.String theType)
          Construct a Measurement, given the Probe who sends the Measurement and a map of field number to field value, and a type for the Measurement.
 
Method Summary
 Measurement addValues(java.util.List<ProbeValue> values)
          Add attribute / values to the measurement.
 Timestamp getDeltaTime()
          Get the delta since the last measurement.
 ID getGroupID()
          Get the group ID for this Measurement
 Probe getProbe()
          Get the probe this Measurement is from
 ID getProbeID()
          Get the ID of the probe this Measurement is from
 long getSequenceNo()
          Get the sequence number of this measurement.
 ID getServiceID()
          Get the service ID of the probe this Measurement is from
 Timestamp getTimestamp()
          Get the timestamp
 java.lang.String getType()
          Get the measurement type
 java.util.List<ProbeValue> getValues()
          Get the attribute / values
 void setGroupID(ID gid)
          Set the groupID.
 void setSequenceNo(long n)
          Set the sequence number of this measurement.
 void setServiceID(ID sid)
          Set the service ID.
 void setType(java.lang.String t)
          Set the measurement type
 java.lang.String toString()
          To String
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ProducerMeasurement

public ProducerMeasurement(Probe aProbe,
                           java.util.List<ProbeValue> attrs)
Construct a Measurement, given the Probe who sends the Measurement and a list of ProbeValues. The default type of the Measurement will be "Measurement".


ProducerMeasurement

public ProducerMeasurement(Probe aProbe,
                           java.util.List<ProbeValue> attrs,
                           java.lang.String theType)
Construct a Measurement, given the Probe who sends the Measurement and a list of ProbeValues, and a type for the Measurement.


ProducerMeasurement

public ProducerMeasurement(Probe aProbe,
                           java.util.Map<java.lang.Integer,java.lang.Object> attrs)
                    throws TypeException
Construct a Measurement, given the Probe who sends the Measurement and a map of field number to field value. The default type of the Measurement will be "Measurement". Throws a TypeException if any of the objects passed in are not valid types for a Measurement.

Throws:
TypeException

ProducerMeasurement

public ProducerMeasurement(Probe aProbe,
                           java.util.Map<java.lang.Integer,java.lang.Object> attrs,
                           java.lang.String theType)
                    throws TypeException
Construct a Measurement, given the Probe who sends the Measurement and a map of field number to field value, and a type for the Measurement. Throws a TypeException if any of the objects passed in are not valid types for a Measurement.

Throws:
TypeException
Method Detail

getTimestamp

public Timestamp getTimestamp()
Get the timestamp

Specified by:
getTimestamp in interface Measurement

getDeltaTime

public Timestamp getDeltaTime()
Get the delta since the last measurement.

Specified by:
getDeltaTime in interface Measurement

getProbe

public Probe getProbe()
Get the probe this Measurement is from

Specified by:
getProbe in interface ProbeMeasurement

getProbeID

public ID getProbeID()
Get the ID of the probe this Measurement is from

Specified by:
getProbeID in interface Measurement

getServiceID

public ID getServiceID()
Get the service ID of the probe this Measurement is from

Specified by:
getServiceID in interface Measurement

setServiceID

public void setServiceID(ID sid)
Set the service ID.

Specified by:
setServiceID in interface ProbeMeasurement

getGroupID

public ID getGroupID()
Get the group ID for this Measurement

Specified by:
getGroupID in interface Measurement

setGroupID

public void setGroupID(ID gid)
Set the groupID.

Specified by:
setGroupID in interface ProbeMeasurement

getType

public java.lang.String getType()
Get the measurement type

Specified by:
getType in interface Measurement

setType

public void setType(java.lang.String t)
Set the measurement type

Specified by:
setType in interface ProbeMeasurement

getSequenceNo

public long getSequenceNo()
Get the sequence number of this measurement.

Specified by:
getSequenceNo in interface Measurement

setSequenceNo

public void setSequenceNo(long n)
Set the sequence number of this measurement.

Specified by:
setSequenceNo in interface ProbeMeasurement

getValues

public java.util.List<ProbeValue> getValues()
Get the attribute / values

Specified by:
getValues in interface Measurement

addValues

public Measurement addValues(java.util.List<ProbeValue> values)
Add attribute / values to the measurement.

Specified by:
addValues in interface ProbeMeasurement

toString

public java.lang.String toString()
To String

Overrides:
toString in class java.lang.Object


RESERVOIR Monitoring 0.6.4