This class represents a basic measurement in the system, in the abstract. Subclasses are required to define the type Value property. This will give rise to specific measurement types such as UnsignedNumericMeasurement, BinaryMeasurement, etc.
More...
|
|
static readonly string | TimestampFormat = "yyyymmddThhMMss.ffffffzzz" |
| |
|
| | Measurement (SerializationInfo info, StreamingContext context) |
| | Creates a measurement and sets its timestamp to 'now'. More...
|
| |
| virtual int | OnCompareTo (object obj) |
| | Called when [compare to]. More...
|
| |
This class represents a basic measurement in the system, in the abstract. Subclasses are required to define the type Value property. This will give rise to specific measurement types such as UnsignedNumericMeasurement, BinaryMeasurement, etc.
- Template Parameters
-
| ValueType | The type of the alue type. |
◆ Measurement()
| Apac.Monitoring.Measurement.Measurement |
( |
SerializationInfo |
info, |
|
|
StreamingContext |
context |
|
) |
| |
|
inlineprotected |
Creates a measurement and sets its timestamp to 'now'.
- Parameters
-
| elementId | The identifier for the element to which this measurement applies. |
| value | The reading for the measurement. |
| source | The source component that gathered the measurement. |
| sensorid | The identifier for the sensor from which the reading came. |
Creates a measurement and sets its timestamp as supplied.
- Parameters
-
| elementId | The identifier for the element to which this measurement applies. |
| value | The reading for the measurement. |
| timestamp | The date and time the measurement was taken. |
| source | The source component that gathered the measurement. |
| sensorid | The identifier for the sensor from which the reading came. |
Creates a measurement and sets its timestamp and compiled value as supplied.
- Parameters
-
| elementId | The identifier for the element to which this measurement applies. |
| value | The reading for the measurement. |
| compiledValue | The compiled or computed value for the measurement. |
| timestamp | The date and time the measurement was taken. |
| source | The source component that gathered the measurement. |
| sensorid | The identifier for the sensor from which the reading came. |
◆ Abort()
| void Apac.Monitoring.Measurement.Abort |
( |
| ) |
|
|
inline |
◆ AddReading()
| void Apac.Monitoring.Measurement.AddReading |
( |
Reading |
reading | ) |
|
|
inline |
Adds a reading.
- Parameters
-
◆ AddSourceMeasurement()
| void Apac.Monitoring.Measurement.AddSourceMeasurement |
( |
Measurement |
sourceMeasurement | ) |
|
|
inline |
Adds a source measurement.
- Parameters
-
| sourceMeasurement | The source measurement. |
◆ CompareTo()
| int Apac.Monitoring.Measurement.CompareTo |
( |
object |
obj | ) |
|
|
inline |
Compares the current instance with another object of the same type.
- Parameters
-
| obj | An object to compare with this instance. |
- Returns
- A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings: Value Meaning Less than zero This instance is less than obj. Zero This instance is equal to obj. Greater than zero This instance is greater than obj.
- Exceptions
-
| T:System.ArgumentException | obj is not the same type as this instance. |
◆ FindSourceMeasurementByTag()
| Measurement Apac.Monitoring.Measurement.FindSourceMeasurementByTag |
( |
string |
tag | ) |
|
|
inline |
Finds a source measurement by tag.
- Parameters
-
- Returns
- Returns the requested measurement, or
null if it cannot be found.
◆ GetAggregateSourceValue()
| virtual decimal Apac.Monitoring.Measurement.GetAggregateSourceValue |
( |
| ) |
|
|
inlinevirtual |
Provides an easy way for subclasses to define the aggregate source value, in the event that there are multiple readings. This value may not be meaningful for all measurements.
- Returns
◆ GetObjectData()
| virtual void Apac.Monitoring.Measurement.GetObjectData |
( |
SerializationInfo |
info, |
|
|
StreamingContext |
context |
|
) |
| |
|
inlinevirtual |
◆ GetReadingByName()
| Reading Apac.Monitoring.Measurement.GetReadingByName |
( |
string |
tagName | ) |
|
|
inline |
Gets the reading with tagName .
- Parameters
-
| tagName | Name of the tag given to the reading. |
- Returns
- The desired reading, or
null.
◆ IsAborted()
| bool Apac.Monitoring.Measurement.IsAborted |
( |
| ) |
|
|
inline |
Determines if the measurement has been aborted.
- Returns
◆ OnCompareTo()
| virtual int Apac.Monitoring.Measurement.OnCompareTo |
( |
object |
obj | ) |
|
|
inlineprotectedvirtual |
Called when [compare to].
- Parameters
-
- Returns
- A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings: Value Meaning Less than zero This instance is less than obj. Zero This instance is equal to obj. Greater than zero This instance is greater than obj.
◆ ToString()
| override string Apac.Monitoring.Measurement.ToString |
( |
| ) |
|
|
inline |
Returns a System.String that represents this instance.
- Returns
- A System.String that represents this instance.
◆ Bucket
| int Apac.Monitoring.Measurement.Bucket |
|
get |
Gets the bucket to which the measurement belongs.
◆ CompiledValue
| virtual decimal Apac.Monitoring.Measurement.CompiledValue |
|
getset |
Gets or sets the compiled value.
The compiled value.
◆ ElementId
| uint? Apac.Monitoring.Measurement.ElementId |
|
get |
Gets the identifier of the element to which this measurement applied.
◆ FullSource
| string Apac.Monitoring.Measurement.FullSource |
|
get |
Gets the name source for this measurement instance.
The source.
Gets the identifier of the sensor that generated the source value for this instance.
The sensor id.
Gets the full name of the measurement's source.
The full source.
◆ Offset
| int Apac.Monitoring.Measurement.Offset |
|
get |
Gets the time offset (in seconds) into the bucket to which this measurement belongs.
◆ ReadingCount
| int Apac.Monitoring.Measurement.ReadingCount |
|
get |
Gets the reading count.
The reading count.
◆ Readings
| Reading [] Apac.Monitoring.Measurement.Readings |
|
get |
Gives subclasses access to the list of readings.
◆ SourceMeasurementCount
| int Apac.Monitoring.Measurement.SourceMeasurementCount |
|
get |
Gets the source measurement count.
The reading count.
◆ SourceMeasurements
| Measurement [] Apac.Monitoring.Measurement.SourceMeasurements |
|
get |
Gives subclasses access to the list of source measurements.
◆ Tag
| object Apac.Monitoring.Measurement.Tag |
|
getset |
Aggregates the specified compiled addition to the current compiled value and flags this instance as aggregated (IsAggregate == true).
- Parameters
-
| compiledAddition | The compiled value to be added. |
Gets or sets the tag for the measurement. This is often used to mark a measurment as a specific input to a formula.
◆ TimestampISO
| string Apac.Monitoring.Measurement.TimestampISO |
|
get |
Gets the timestamp in ISO string format.
The timestamp ISO.
◆ UnitLabel
| string Apac.Monitoring.Measurement.UnitLabel |
|
getset |
Gets or sets a value indicating whether this instance is aggregate.
true if this instance is aggregate; otherwise, false.
The documentation for this class was generated from the following file:
- /var/lib/jenkins/workspace/apac/APAC/APACCore/Monitoring/Measurement.cs