• DR-IT Software
  • Products
  • Documentation
  • Product page
  • Examples
  • API reference
  • Support
Show / Hide Table of Contents

Class DoubleUnit

Double value and its unit.

Inheritance
object
DoubleUnit
Inherited Members
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
Namespace: DRIT.Presentation.Office
Assembly: DRIT.Presentation.dll
Syntax
public class DoubleUnit

Constructors

DoubleUnit(double, ScreenMeasurementUnit)

Initializes a new instance of the double unit class.

Declaration
public DoubleUnit(double value, ScreenMeasurementUnit unit)
Parameters
Type Name Description
double value

The value supplied to this operation.

ScreenMeasurementUnit unit

The unit used for the conversion.

Properties

this[ScreenMeasurementUnit]

Gets or sets the value associated with this object.

Declaration
public double this[ScreenMeasurementUnit unit] { get; }
Parameters
Type Name Description
ScreenMeasurementUnit unit
Property Value
Type Description
double

Unit

Gets or sets the unit associated with this object.

Declaration
public ScreenMeasurementUnit Unit { get; set; }
Property Value
Type Description
ScreenMeasurementUnit

Value

Gets or sets the value associated with this object.

Declaration
public double Value { get; set; }
Property Value
Type Description
double

Methods

GetValue(ScreenMeasurementUnit)

Gets the value from this double unit.

Declaration
public double GetValue(ScreenMeasurementUnit unit)
Parameters
Type Name Description
ScreenMeasurementUnit unit

The unit used for the conversion.

Returns
Type Description
double

The get value value produced by the operation.

GetValue(ScreenMeasurementUnit, UnitConversionOptions)

Gets the value from this double unit.

Declaration
public double GetValue(ScreenMeasurementUnit unit, UnitConversionOptions options)
Parameters
Type Name Description
ScreenMeasurementUnit unit

The unit used for the conversion.

UnitConversionOptions options

The options that control the operation.

Returns
Type Description
double

The get value value produced by the operation.

TryGetValue(ScreenMeasurementUnit, UnitConversionOptions?, out double)

Attempts to perform the get value and reports whether it succeeded.

Declaration
public bool TryGetValue(ScreenMeasurementUnit unit, UnitConversionOptions? options, out double value)
Parameters
Type Name Description
ScreenMeasurementUnit unit

The unit used for the conversion.

UnitConversionOptions options

The options that control the operation.

double value

The value supplied to this operation.

Returns
Type Description
bool

true if the operation succeeds; otherwise, false.

TryGetValue(ScreenMeasurementUnit, out double)

Attempts to perform the get value and reports whether it succeeded.

Declaration
public bool TryGetValue(ScreenMeasurementUnit unit, out double value)
Parameters
Type Name Description
ScreenMeasurementUnit unit

The unit used for the conversion.

double value

The value supplied to this operation.

Returns
Type Description
bool

true if the operation succeeds; otherwise, false.

Back to top

DR-IT Software documentation

DR-IT Software · Products · Documentation index · Product page · Downloads · Support · Licensing

Generated by DocFX