mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-07-01 15:50:13 +00:00
Add missing method signatures
This commit is contained in:
38
types/cuint/index.d.ts
vendored
38
types/cuint/index.d.ts
vendored
@@ -4,21 +4,47 @@
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
export interface Uint {
|
||||
clone(): this;
|
||||
// Math
|
||||
add(x: this): this;
|
||||
subtract(x: this): this;
|
||||
multiply(x: this): this;
|
||||
xor(x: this): this;
|
||||
rotl(n: number): this;
|
||||
shiftRight(n: number): this;
|
||||
div(x: this): this;
|
||||
|
||||
// Compare
|
||||
equals(x: this): boolean;
|
||||
eq(x: this): boolean;
|
||||
greaterThan(x: this): boolean;
|
||||
gt(x: this): boolean;
|
||||
lessThan(x: this): boolean;
|
||||
lt(x: this): boolean;
|
||||
|
||||
// Bitwise
|
||||
negate(): this;
|
||||
or(x: this): this;
|
||||
and(x: this): this;
|
||||
xor(x: this): this;
|
||||
not(x: this): this;
|
||||
shiftRight(n: number): this;
|
||||
shiftr(n: number): this;
|
||||
shiftLeft(n: number): this;
|
||||
shiftl(n: number): this;
|
||||
rorateLeft(n: number): this;
|
||||
rotl(n: number): this;
|
||||
rorateRight(n: number): this;
|
||||
rotr(n: number): this;
|
||||
|
||||
// Deserialize
|
||||
fromNumber(n: number): this;
|
||||
fromBits(...bits: number[]): this;
|
||||
fromString(integer: string, radix?: number): this;
|
||||
|
||||
// Serialize
|
||||
toNumber(): number;
|
||||
toString(base?: number): string;
|
||||
clone(): this;
|
||||
|
||||
_low: number;
|
||||
_high: number;
|
||||
|
||||
toString(base?: number): string;
|
||||
}
|
||||
|
||||
export interface UintConstructor<T extends Uint> {
|
||||
|
||||
Reference in New Issue
Block a user