Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

Int Class Reference

Inheritance diagram for Int:

Number List of all members.

Public Member Functions

void setRadix (Radix radix)
void setFill (tChar fill, uint width)
tChar[] format (uint x)

Static Public Member Functions

tChar[] format (int i)
tChar[] format (uint i, Radix radix, tChar fill=tChar.init)
tChar[] format (tChar[] dst, int i)
tChar[] format (tChar[] dst, uint i, Radix radix, tChar fill=tChar.init)
uint parse (tChar[] src, Radix radix=Radix.Decimal, uint *ate=null)

Public Attributes

alias put opCall
private tChar fill
private tChar space [32]
private int width = space.length
private Radix radix = Radix.Decimal

Private Types

enum  Radix { Binary = 2, Octal = 8, Decimal = 10, Hexadecimal = 16 }

Static Private Member Functions

 this ()
package uint trim (tChar[] digits, inout bool sign, Radix *radix=null)

Detailed Description

A set of functions for converting between string and numeric values.

Used by modules Token and DisplayWriter

Definition at line 52 of file Int.d.


Member Enumeration Documentation

enum Radix [inherited]
 

Enumeration values:
Binary 
Octal 
Decimal 
Hexadecimal 

Definition at line 51 of file Number.d.


Member Function Documentation

void setRadix Radix  radix  )  [inline]
 

Definition at line 66 of file Int.d.

void setFill tChar  fill,
uint  width
[inline]
 

Definition at line 76 of file Int.d.

tChar [] format uint  x  )  [inline]
 

Definition at line 87 of file Int.d.

References fill, radix, space, and width.

Referenced by format().

tChar [] format int  i  )  [inline, static]
 

Definition at line 97 of file Int.d.

References format().

tChar [] format uint  i,
Radix  radix,
tChar  fill = tChar.init
[inline, static]
 

Definition at line 107 of file Int.d.

References format().

tChar [] format tChar[]  dst,
int  i
[inline, static]
 

Definition at line 117 of file Int.d.

References assert().

tChar [] format tChar[]  dst,
uint  i,
Radix  radix,
tChar  fill = tChar.init
[inline, static]
 

Definition at line 134 of file Int.d.

References len.

uint parse tChar[]  src,
Radix  radix = Radix.Decimal,
uint *  ate = null
[inline, static]
 

Definition at line 183 of file Int.d.

References Number::trim().

this  )  [inline, static, inherited]
 

Definition at line 61 of file Number.d.

References Number::error.

package uint trim tChar[]  digits,
inout bool  sign,
Radix radix = null
[inline, static, inherited]
 

Definition at line 70 of file Number.d.

References len.

Referenced by Long::parse(), parse(), and Double::parse().


Member Data Documentation

alias put opCall
 

Definition at line 55 of file Int.d.

private tChar fill
 

Definition at line 57 of file Int.d.

Referenced by format().

private tChar space[32]
 

Definition at line 58 of file Int.d.

Referenced by format().

private int width = space.length
 

Definition at line 59 of file Int.d.

Referenced by format().

private Radix radix = Radix.Decimal
 

Definition at line 60 of file Int.d.

Referenced by format().


The documentation for this class was generated from the following file:
Generated on Sun Mar 6 00:31:11 2005 for Mango by doxygen 1.3.6