Class TextConversion
Defines a text conversion formula.
Inherited Members
Namespace: MESL.SqlRace.Domain
Assembly: MESL.SqlRace.Domain.dll
Syntax
public class TextConversion : ConversionBase
Constructors
TextConversion()
Initialises a new instance of the TextConversion class.
Declaration
public TextConversion()
TextConversion(String, String, String, Double[], String[], String)
Initialises a new instance of the TextConversion class.
Declaration
public TextConversion(string name, string units, string formatString, double[] values, string[] stringValues, string defaultValue)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | The name of the conversion. |
System.String | units | The units used by the conversion. |
System.String | formatString | The format string. |
System.Double[] | values | The values. |
System.String[] | stringValues | The string values. |
System.String | defaultValue | The default value. |
Properties
DefaultValue
Gets or sets a string that is used when there is no mapping for a supplied value with one of the raw values in the map.
Declaration
public string DefaultValue { get; set; }
Property Value
Type | Description |
---|---|
System.String |
StringValues
Gets or sets an array of strings that map to the supplied raw values.
Declaration
public string[] StringValues { get; set; }
Property Value
Type | Description |
---|---|
System.String[] |
TableSize
Gets the number of elements that make up the mapping.
Declaration
public int TableSize { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Values
Gets or sets an array of raw values that populate the map.
Declaration
public double[] Values { get; set; }
Property Value
Type | Description |
---|---|
System.Double[] |
Methods
Create(String, String, String, Double[], String[], String)
Create the instance.
Declaration
public static TextConversion Create(string name, string units, string formatString, double[] values, string[] stringValues, string defaultValue)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | |
System.String | units | |
System.String | formatString | |
System.Double[] | values | |
System.String[] | stringValues | |
System.String | defaultValue |
Returns
Type | Description |
---|---|
TextConversion | The TextConversion. |