DK for Java | tatukgis.jdk.TGIS_CSUnits.AsLinear | Constructors | Methods | Properties
Convert a linear value to a string representation with the appropriate unit symbol.
// Java public java.lang.String AsLinear( double _value, bool _prec );
// Oxygene public function AsLinear( _value : Double; _prec : Boolean ) : String;
| Name | Type | Description |
|---|---|---|
| _value | double Double | Value in base linear units. |
| _prec | bool Boolean | If True, fixed decimal digits are used; if False, only significant digits are shown without trailing zeros. |
| Type | Description |
|---|---|
| java.lang.String String | Formatted value with unit symbol. |
If the unit type is TGIS_CSUnitsType.Auto, the returned string uses an automatically selected linear subunit.
USAGE: Format a measured length for display using the most suitable linear unit symbol.
length_text = units.AsLinear(shape.LengthCS, True)