C# Class MiscUtil.Conversion.DoubleConverter.ArbitraryDecimal

Private class used for manipulating sequences of decimal digits.
显示文件 Open project: jadref/buffer_bci

Public Methods

Method Description
ToString ( ) : String

Converts the value to a proper decimal string representation.

Private Methods

Method Description
ArbitraryDecimal ( long x ) : System

Constructs an arbitrary decimal expansion from the given long. The long must not be negative.

MultiplyBy ( int amount ) : void

Multiplies the current expansion by the given amount, which should only be 2 or 5.

Normalize ( ) : void

Removes leading/trailing zeroes from the expansion.

Shift ( int amount ) : void

Shifts the decimal point; a negative value makes the decimal expansion bigger (as fewer digits come after the decimal place) and a positive value makes the decimal expansion smaller.

Method Details

ToString() public method

Converts the value to a proper decimal string representation.
public ToString ( ) : String
return String