-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathALGO_compiled.d.ts
82 lines (82 loc) · 3.64 KB
/
ALGO_compiled.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
import { Stdlib_Backend_Base } from './interfaces';
import { MkPayAmt } from './shared_impl';
import { ethers } from 'ethers';
import { CBR_Null, CBR_Bool, CBR_UInt, CBR_Bytes, CBR_Address, CBR_Digest, CBR_Object, CBR_Data, CBR_Array, CBR_Tuple, CBR_Struct, CBR_Val, BackendTy } from './CBR';
type BigNumber = ethers.BigNumber;
declare const BigNumber: typeof ethers.BigNumber;
export declare const UInt_max: BigNumber;
export type NV = Uint8Array;
export interface ALGO_Ty<BV extends CBR_Val> extends BackendTy<BV> {
netSize: number;
toNet(bv: BV): NV;
fromNet(nv: NV): BV;
netName: string;
}
export declare const digest: (ts_: any, vs_: any) => string;
export declare const T_Null: ALGO_Ty<CBR_Null>;
export declare const T_Bool: ALGO_Ty<CBR_Bool>;
export declare const T_UInt: ALGO_Ty<CBR_UInt>;
export declare const T_UInt256: ALGO_Ty<CBR_UInt>;
/** @description For hex strings representing bytes */
export declare const bytestringyNet: (len: number) => {
netSize: number;
netName: string;
toNet: (bv: string) => NV;
fromNet: (nv: NV) => string;
};
export declare const T_Bytes: (len: number) => ALGO_Ty<CBR_Bytes>;
export declare const T_BytesDyn: ALGO_Ty<CBR_Bytes>;
export declare const T_StringDyn: ALGO_Ty<CBR_Bytes>;
export declare const T_Digest: ALGO_Ty<CBR_Digest>;
export declare const addressToHex: (x: string) => string;
export declare const addressFromHex: (hexAddr: string) => string;
export declare const extractAddr: (x: any) => string;
export declare const T_Address: ALGO_Ty<CBR_Address>;
export declare const T_Contract: ALGO_Ty<Contract>;
export declare const T_Array: (co: ALGO_Ty<CBR_Val>, size_u: unknown) => ALGO_Ty<CBR_Array>;
export declare const T_Tuple: (cos: Array<ALGO_Ty<CBR_Val>>) => ALGO_Ty<CBR_Tuple>;
export declare const T_Struct: (cos: Array<[string, ALGO_Ty<CBR_Val>]>) => ALGO_Ty<CBR_Struct>;
export declare const T_Object: (coMap: {
[key: string]: ALGO_Ty<CBR_Val>;
}) => ALGO_Ty<CBR_Object>;
export declare const T_Data: (coMap: {
[key: string]: ALGO_Ty<CBR_Val>;
}) => ALGO_Ty<CBR_Data>;
export declare const addressEq: (x: any, y: any) => boolean;
export declare const digestEq: (x: any, y: any) => boolean;
export declare const digest_xor: (xd: string, yd: string) => string;
export declare const bytes_xor: (x: string, y: string) => string;
export declare const btoiLast8: (b: string) => ethers.BigNumber;
export type Token = CBR_UInt;
export type Contract = CBR_UInt;
export declare const ctcAddrEq: (x: unknown, y: unknown) => boolean;
export declare const tokenEq: (x: unknown, y: unknown) => boolean;
export type PayAmt = MkPayAmt<Token>;
export declare const typeDefs: {
T_Null: ALGO_Ty<null>;
T_Bool: ALGO_Ty<boolean>;
T_UInt: ALGO_Ty<ethers.BigNumber>;
T_UInt256: ALGO_Ty<ethers.BigNumber>;
T_Bytes: (len: number) => ALGO_Ty<CBR_Bytes>;
T_BytesDyn: ALGO_Ty<CBR_Bytes>;
T_StringDyn: ALGO_Ty<CBR_Bytes>;
T_Address: ALGO_Ty<string>;
T_Contract: ALGO_Ty<ethers.BigNumber>;
T_Digest: ALGO_Ty<string>;
T_Token: ALGO_Ty<ethers.BigNumber>;
T_Object: (coMap: {
[key: string]: ALGO_Ty<CBR_Val>;
}) => ALGO_Ty<CBR_Object>;
T_Data: (coMap: {
[key: string]: ALGO_Ty<CBR_Val>;
}) => ALGO_Ty<CBR_Data>;
T_Array: (co: ALGO_Ty<CBR_Val>, size_u: unknown) => ALGO_Ty<CBR_Array>;
T_Tuple: (cos: Array<ALGO_Ty<CBR_Val>>) => ALGO_Ty<CBR_Tuple>;
T_Struct: (cos: Array<[string, ALGO_Ty<CBR_Val>]>) => ALGO_Ty<CBR_Struct>;
};
export declare const emptyContractInfo = 0;
type ConnectorTy = ALGO_Ty<any>;
type ContractInfo = Contract;
export declare const stdlib: Stdlib_Backend_Base<Token, ContractInfo, ConnectorTy>;
export {};
//# sourceMappingURL=ALGO_compiled.d.ts.map