2019-05-15 01:48:48 +03:00
|
|
|
import { Bytes, Hexable } from "@ethersproject/bytes";
|
|
|
|
export declare type BigNumberish = BigNumber | Bytes | string | number;
|
2019-06-12 00:57:04 +03:00
|
|
|
export declare function isBigNumberish(value: any): value is BigNumberish;
|
2019-05-15 01:48:48 +03:00
|
|
|
export declare class BigNumber implements Hexable {
|
|
|
|
readonly _hex: string;
|
2019-06-12 00:57:04 +03:00
|
|
|
readonly _isBigNumber: boolean;
|
2019-05-15 01:48:48 +03:00
|
|
|
constructor(constructorGuard: any, hex: string);
|
|
|
|
fromTwos(value: number): BigNumber;
|
|
|
|
toTwos(value: number): BigNumber;
|
|
|
|
abs(): BigNumber;
|
|
|
|
add(other: BigNumberish): BigNumber;
|
|
|
|
sub(other: BigNumberish): BigNumber;
|
|
|
|
div(other: BigNumberish): BigNumber;
|
|
|
|
mul(other: BigNumberish): BigNumber;
|
|
|
|
mod(other: BigNumberish): BigNumber;
|
|
|
|
pow(other: BigNumberish): BigNumber;
|
2020-04-16 01:28:04 +03:00
|
|
|
and(other: BigNumberish): BigNumber;
|
|
|
|
or(other: BigNumberish): BigNumber;
|
|
|
|
xor(other: BigNumberish): BigNumber;
|
|
|
|
mask(value: number): BigNumber;
|
|
|
|
shl(value: number): BigNumber;
|
|
|
|
shr(value: number): BigNumber;
|
2019-05-15 01:48:48 +03:00
|
|
|
eq(other: BigNumberish): boolean;
|
|
|
|
lt(other: BigNumberish): boolean;
|
|
|
|
lte(other: BigNumberish): boolean;
|
|
|
|
gt(other: BigNumberish): boolean;
|
|
|
|
gte(other: BigNumberish): boolean;
|
2020-04-16 01:28:04 +03:00
|
|
|
isNegative(): boolean;
|
2019-05-15 01:48:48 +03:00
|
|
|
isZero(): boolean;
|
|
|
|
toNumber(): number;
|
|
|
|
toString(): string;
|
|
|
|
toHexString(): string;
|
|
|
|
static from(value: any): BigNumber;
|
|
|
|
static isBigNumber(value: any): value is BigNumber;
|
|
|
|
}
|