gnablib
Version:
A lean, zero dependency library to provide a useful base for your project.
53 lines (52 loc) • 1.67 kB
TypeScript
/*! Copyright 2025 the gnablib contributors MPL-1.1 */
import { IInt, IIntMut } from '../interfaces/IUint.js';
import { AInt } from './_AInt.js';
export declare class I64 extends AInt implements IInt<I64> {
protected constructor(arr: Uint32Array, pos: number, name?: string);
static fromInt(i52: number): I64;
static fromI32s(...ns: number[]): I64;
static fromBytesBE(src: Uint8Array, pos?: number): I64;
static mount(arr: Uint32Array, pos?: number): I64;
clone(): I64;
mut(): I64Mut;
lShift(by: number): I64;
rShift(by: number): I64;
lRot(by: number): I64;
rRot(by: number): I64;
xor(o: I64): I64;
or(o: I64): I64;
and(o: I64): I64;
not(): I64;
add(o: I64): I64;
sub(o: I64): I64;
mul(o: I64): I64;
get negative(): boolean;
abs(): I64;
eq(o: I64): boolean;
gt(o: I64): boolean;
gte(o: I64): boolean;
lt(o: I64): boolean;
lte(o: I64): boolean;
static get zero(): I64;
}
export declare class I64Mut extends I64 implements IIntMut<I64Mut, I64> {
protected constructor(arr: Uint32Array, pos: number);
set(v: I64): I64Mut;
zero(): I64Mut;
static fromInt(i52: number): I64Mut;
static fromI32s(...ns: number[]): I64Mut;
static fromBytesBE(src: Uint8Array, pos?: number): I64Mut;
static mount(arr: Uint32Array, pos?: number): I64Mut;
lShiftEq(by: number): this;
lRotEq(by: number): this;
rShiftEq(by: number): this;
rRotEq(by: number): this;
xorEq(o: I64): this;
orEq(o: I64): this;
andEq(o: I64): this;
notEq(): this;
addEq(o: I64): this;
subEq(o: I64): this;
mulEq(o: I64): this;
absEq(): this;
}