Click or drag to resize

UserUnitProvider Class

A IUnitProvider based on a specified set of unit definitions.

If a quantity ID is not provided when adding a user units, it will match on the eumItem value only.

Inheritance Hierarchy
SystemObject
  DHI.Mike1D.GenericUserUnitProvider

Namespace:  DHI.Mike1D.Generic
Assembly:  DHI.Mike1D.Generic (in DHI.Mike1D.Generic.dll) Version: 19.0.0.0 (11.1.1.1111)
Syntax
public class UserUnitProvider : IUnitProvider

The UserUnitProvider type exposes the following members.

Constructors
  NameDescription
Public methodUserUnitProvider
Initializes a new instance of the UserUnitProvider class
Top
Methods
  NameDescription
Public methodAdd(UserUnitInfo)
Add user unit to unit provider
Public methodAdd(eumItem, eumUnit)
Add user unit to unit provider, based on eumItem type
Protected methodAdd(UserUnitProviderUnitSearchType, UserUnitInfo)
Add user unit to unit provider, with the given search type
Public methodAdd(String, eumItem, eumUnit)
Add user unit to unit provider, based on Id of quantity
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodGetUserUnit(eumItem)
Return user unit for EUM item type
Public methodGetUserUnit(String, eumItem)
Return user unit
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Public methodUpdate(UserUnitInfo)
Update existing unit.
Protected methodUpdate(UserUnitInfo, UserUnitProviderUnitSearchType)
Top
Fields
Extension Methods
  NameDescription
Public Extension MethodGetUnitConversionFactor(eumItem, eumUnit)Overloaded.
Get a unit conversion factor for EUM quantity
(Defined by Util.)
Public Extension MethodGetUnitConversionFactor(eumItem, eumUnit, eumUnit)Overloaded.
Get a unit conversion factor for EUM quantity
(Defined by Util.)
Public Extension MethodGetUserUnitOrDefault
Get a unit conversion factor for EUM quantity
(Defined by Util.)
Public Extension MethodUpdateQuantityUserUnit
Update quantity with user unit, if user unit is available
(Defined by Util.)
Public Extension MethodUserUnitToString
Return a unit as a string
(Defined by Util.)
Public Extension MethodValueInUserUnit(eumItem, Double)Overloaded.
Convert a value to user unit and return as a string
(Defined by Util.)
Public Extension MethodValueInUserUnit(eumQuantity, Double)Overloaded.
Convert a value to user unit and return as a string
(Defined by Util.)
Public Extension MethodValueInUserUnitToString
Convert a value to user unit and return as a string
(Defined by Util.)
Public Extension MethodValueInUserUnitToStringWithUnit
Convert a value to user unit and return as a string
(Defined by Util.)
Top
See Also