Constructors
constructor
- new FixedNumber(constructorGuard: any, hex: string, value: string, format?: FixedFormat): FixedNumber
-
Parameters
-
constructorGuard: any
-
hex: string
-
value: string
-
Optional
format: FixedFormat
Properties
Readonly
_hex
_hex: string
Readonly
_isFixedNumber
_isFixedNumber: boolean
Readonly
_value
_value: string
Readonly
format
format: FixedFormat
Methods
_checkFormat
- _checkFormat(other: FixedNumber): void
-
Returns void
addUnsafe
- addUnsafe(other: FixedNumber): FixedNumber
-
ceiling
- ceiling(): FixedNumber
-
divUnsafe
- divUnsafe(other: FixedNumber): FixedNumber
-
floor
- floor(): FixedNumber
-
isNegative
- isNegative(): boolean
-
Returns boolean
isZero
- isZero(): boolean
-
Returns boolean
mulUnsafe
- mulUnsafe(other: FixedNumber): FixedNumber
-
round
- round(decimals?: number): FixedNumber
-
Parameters
-
Optional
decimals: number
subUnsafe
- subUnsafe(other: FixedNumber): FixedNumber
-
toFormat
- toFormat(format: string | FixedFormat): FixedNumber
-
Parameters
-
format: string | FixedFormat
toHexString
- toHexString(width?: number): string
-
Returns string
toString
- toString(): string
-
Returns string
toUnsafeFloat
- toUnsafeFloat(): number
-
Returns number
Static
from
- from(value: any, format?: string | number | FixedFormat): FixedNumber
-
Parameters
-
value: any
-
Optional
format: string | number | FixedFormat
Static
fromBytes
- fromBytes(value: BytesLike, format?: string | number | FixedFormat): FixedNumber
-
Parameters
-
-
Optional
format: string | number | FixedFormat
Static
fromString
- fromString(value: string, format?: string | number | FixedFormat): FixedNumber
-
Parameters
-
value: string
-
Optional
format: string | number | FixedFormat
Static
fromValue
- fromValue(value: BigNumber, decimals?: BigNumberish, format?: string | number | FixedFormat): FixedNumber
-
Parameters
-
-
-
Optional
format: string | number | FixedFormat
Static
isFixedNumber
- isFixedNumber(value: any): value is FixedNumber
-