AP&C API Reference
Public Member Functions | Protected Member Functions | Properties | Events | List of all members
Apac.Monitoring.MeasurementUnit Class Referenceabstract

This construct models the units used to describe a given measurement. It is needed as a code construct, rather than a simple string, because we need to drive the configuration UI with it, and we need to reference it from our IMeasurementFormula implementations, and we don't want them to get mixed up between the two. A simple enumeration with a translation function won't work because we need the list to be extensible when adding in new formulae. So each formula will provide its own concrete implementation of MeasurementUnit. More...

Inheritance diagram for Apac.Monitoring.MeasurementUnit:
Apac.Plugins.Btu Apac.Plugins.DegreesCelsius Apac.Plugins.DegreesFahrenheit Apac.Plugins.Gpm Apac.Plugins.Kilowatts Apac.Plugins.NullUnit Apac.Plugins.Percent

Public Member Functions

System.Xml.Schema.XmlSchema GetSchema ()
 
void ReadXml (System.Xml.XmlReader reader)
 
void WriteXml (System.Xml.XmlWriter writer)
 
MeasurementUnit Clone ()
 

Protected Member Functions

 MeasurementUnit (string name, string singular, string plural)
 
virtual void OnReadXml (System.Xml.XmlReader reader)
 
virtual void OnWriteXml (System.Xml.XmlWriter writer)
 
abstract MeasurementUnit OnClone ()
 
virtual void OnPropertyChanged (string name)
 

Properties

virtual string Name [get]
 
virtual string LabelSingular [get]
 
virtual string LabelPlural [get]
 
string Location [get]
 

Events

PropertyChangedEventHandler PropertyChanged
 The event that is raised when a property value changes. More...
 

Detailed Description

This construct models the units used to describe a given measurement. It is needed as a code construct, rather than a simple string, because we need to drive the configuration UI with it, and we need to reference it from our IMeasurementFormula implementations, and we don't want them to get mixed up between the two. A simple enumeration with a translation function won't work because we need the list to be extensible when adding in new formulae. So each formula will provide its own concrete implementation of MeasurementUnit.

Event Documentation

◆ PropertyChanged

PropertyChangedEventHandler Apac.Monitoring.MeasurementUnit.PropertyChanged

The event that is raised when a property value changes.


The documentation for this class was generated from the following file: