UNPKG

tolk-codegen

Version:

## Example generator ### Create builder file in root folder ``builder.ts``

36 lines (35 loc) 1.8 kB
import "reflect-metadata"; import { DictionaryKey, DictionaryKeyTypes, DictionaryValue } from "@ton/core"; import { Maybe } from "@ton/core/dist/utils/maybe"; export declare enum DataType { INT = "int", UINT = "uint", ADDRESS = "address", REF = "ref", STRING_TAIL = "stringTail", COINS = "coins", BIT = "bit", DICT = "dict", SLICE = "slice" } export declare enum MetadataKey { PROPERTIES = "tlb:properties", DATATYPE = "tlb:dataType", MAY_BE = "tlb:bayBe", SIZE = "tlb:size", DICT = "tlb:dict", OP = "tlb:op" } export declare function DefineCell(): (constructor: Function) => void; export declare function StoreUint(size: number): (prototype: any, propertyKey: string) => void; export declare function StoreInt(size: number): (prototype: any, propertyKey: string) => void; export declare function StoreAddress(): (prototype: any, propertyKey: string) => void; export declare function StoreRef(): (prototype: any, propertyKey: string) => void; export declare function StoreStringTail(): (prototype: any, propertyKey: string) => void; export declare function StoreCoins(): (prototype: any, propertyKey: string) => void; export declare function StoreBit(): (prototype: any, propertyKey: string) => void; export declare function StoreSliceRemaining(): (prototype: any, propertyKey: string) => void; export declare function StoreSlice(size: number): (prototype: any, propertyKey: string) => void; export declare function MayBe(): (prototype: any, propertyKey: string) => void; export declare function DefineMessage(op?: bigint): (constructor: Function) => void; export declare function StoreDict<K extends DictionaryKeyTypes, V>(key?: Maybe<DictionaryKey<K>>, value?: Maybe<DictionaryValue<V>>): (prototype: any, propertyKey: string) => void;