Click or drag to resize

LengthUnit Structure

Represents a length unit.

Namespace:  Rhino
Assembly:  RhinoCommon (in RhinoCommon.dll)
Since: 9.0
Syntax
public readonly struct LengthUnit : IEquatable<LengthUnit>, 
	IComparable<LengthUnit>

The LengthUnit type exposes the following members.

Properties
  NameDescription
Public propertyDisplayName
Upper case plural localized unit name.
Public propertyDisplaySymbol
Lower case singular localized unit symbol.
Public propertyName
Non localized lower case plural unit name.
Public propertySymbol
Non localized unit symbol string.
Top
Methods
  NameDescription
Public methodCompareTo
Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object.
Public methodEquals(LengthUnit)
Indicates whether the current object is equal to another object of the same type.
Public methodEquals(Object)
Indicates whether the current object is equal to another object of the same type.
(Overrides ValueTypeEquals(Object).)
Public methodStatic memberFromCustomUnitSystem
Creates a custom LengthUnit based on its size expressed on a known UnitSystem.
Public methodStatic memberFromKnownUnitSystem
Constructs a LengthUnit from a UnitSystem.
Public methodGetHashCode
Returns the hash code for this instance.
(Overrides ValueTypeGetHashCode.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodStatic memberIsCustom
Determines whether the specified value is a custom unit.
Public methodStatic memberIsKnownLengthUnit
Determines whether the provided value is a known unit system.
Public methodIsKnownUnitSystem
Determines whether the instance value is a known unit system.
Public methodStatic memberIsNone
Determines whether the specified value is None.
Public methodStatic memberIsUnset
Determines whether the specified value is Unset.
Public methodStatic memberScale
Computes the scale factor for changing a measurement on different units.
Public methodSize
Returns the size of this unit expressed on a different length unit.
Public methodToString
Returns the fully qualified type name of this instance.
(Inherited from ValueType.)
Public methodToUnitSystem(Double)
Returns a UnitSystem equivalent to this instance and its size expressed on meters.
Public methodToUnitSystem(Double, ISetUnitSystem)
Returns the most similar UnitSystem to this instance available on unitSystems set.
Top
Operators
  NameDescription
Public operatorStatic memberEquality
Equality operator.
Public operatorStatic memberGreaterThan
Greater than operator.
Public operatorStatic memberGreaterThanOrEqual
Greater than or equal operator.
Public operatorStatic memberInequality
Inequality operator.
Public operatorStatic memberLessThan
Less than operator.
Public operatorStatic memberLessThanOrEqual
Less than or equal operator.
Top
Fields
  NameDescription
Public fieldStatic memberCentimeters
1 millimeter = 1.0e-2 meters
Public fieldStatic memberFeet
1 foot = 0.3048 meters = 12 inches
Public fieldStatic memberInches
1 inch = 0.0254 meters = 1/12 foot
Public fieldStatic memberKilometers
1 kilometer = 1.0e+3 meters
Public fieldStatic memberMeters
SI meter length unit
Public fieldStatic memberMiles
1 yard = 1609.344 meters = 5280 feet
Public fieldStatic memberMillimeters
1 millimeter = 1.0e-3 meters
Public fieldStatic memberNone
No unit
Public fieldStatic memberUnset
Unset unit
Public fieldStatic memberYards
1 yard = 0.9144 meters = 3 feet
Top
See Also