new NumberOp( value )

Description

A Number like class that supports operations.

For lack of any other standard, methods will be named like those in Python's operator module.

All operations should return this to allow chaining.

The existence of the toJSON, toString, and valueOf, methods will probably allow this class to work in many situations through type coercion.

Parameters
Name Type Description
value number

Initial value, parsed by Number.

Details

Methods


valueOf() → {number}

Returns

Current value.

Details

toString() → {string}

Returns

Current value.

Details

toJSON() → {number}

Returns

Current value.

Details

assign( value ) → {NexusHoratio.base~NumberOp}

Parameters
Name Type Default Description
value number 0

Number to assign.

Returns
Details

add( value ) → {NexusHoratio.base~NumberOp}

Parameters
Name Type Description
value number

Number to add.

Returns
Details