Greet 2014
Documentation for the GREET 2014 API
 All Classes Namespaces Functions Variables Enumerations Properties Events
Greet.UnitLib.IQuantity Interface Reference

A unit group represents "energy" or "volume" the default unit used are the unit used by the calculations engine, they're all SI. The user prefered unit represents the unit that the user selected to be presented on the GUI More...

Inheritance diagram for Greet.UnitLib.IQuantity:
Greet.UnitLib.BaseQuantity Greet.UnitLib.DerivedQuantity Greet.UnitLib.Quantity

Public Member Functions

double ConvertFromDefaultToOverride (double valueToConvert)
 Takes a value in the default unit and converts it to the user prefered unit More...
 
double ConvertFromDefaultToSpecific (double valueToConvert, string unit)
 Converts a value represented in default unit to a specified unit (this must be a unit that belongs to the same group) More...
 
double ConvertFromOverrideToDefault (double valueToConvert)
 Takes a value in the override unit, and converts it to the default unit Usefull to parse user inputs in textboxes More...
 

Properties

string DisplayUnitStr [get]
 The prefered unit used for this group in order to represent a value on the user interface More...
 
string Name [get]
 Unique name of the unit group More...
 
string SIUnitStr [get]
 The default unit used for this group in SI unit. This is the unit that is used across the calculations More...
 

Detailed Description

A unit group represents "energy" or "volume" the default unit used are the unit used by the calculations engine, they're all SI. The user prefered unit represents the unit that the user selected to be presented on the GUI

Member Function Documentation

double Greet.UnitLib.IQuantity.ConvertFromDefaultToOverride ( double  valueToConvert)

Takes a value in the default unit and converts it to the user prefered unit

Parameters
valueToConvertValue in default unit to be converted
Returns
Value converted in user prefered unit

Implemented in Greet.UnitLib.DerivedQuantity, Greet.UnitLib.Quantity, and Greet.UnitLib.BaseQuantity.

double Greet.UnitLib.IQuantity.ConvertFromDefaultToSpecific ( double  valueToConvert,
string  unit 
)

Converts a value represented in default unit to a specified unit (this must be a unit that belongs to the same group)

Parameters
valueToConvertValue in default unit to be converted
unitUnit that belongs to that group in which the value will be converted
Returns
The converted value in the new unit

Implemented in Greet.UnitLib.DerivedQuantity, Greet.UnitLib.Quantity, and Greet.UnitLib.BaseQuantity.

double Greet.UnitLib.IQuantity.ConvertFromOverrideToDefault ( double  valueToConvert)

Takes a value in the override unit, and converts it to the default unit Usefull to parse user inputs in textboxes

Parameters
valueToConvertValue in override unit to be converted
Returns
Value converted in default unit<returns>

Implemented in Greet.UnitLib.DerivedQuantity, Greet.UnitLib.Quantity, and Greet.UnitLib.BaseQuantity.

Property Documentation

string Greet.UnitLib.IQuantity.DisplayUnitStr
get

The prefered unit used for this group in order to represent a value on the user interface

string Greet.UnitLib.IQuantity.Name
get

Unique name of the unit group

string Greet.UnitLib.IQuantity.SIUnitStr
get

The default unit used for this group in SI unit. This is the unit that is used across the calculations


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