2018-03-07 23:36:05 +00:00
|
|
|
declare module 'ethereumjs-abi' {
|
|
|
|
import BN from 'bn.js';
|
2018-04-14 22:21:33 +00:00
|
|
|
type Values = (string | number | boolean | BN | Buffer | Array<any>)[];
|
2018-03-07 23:36:05 +00:00
|
|
|
type Types = string[];
|
|
|
|
export function eventID(name: string, types: Types): Buffer;
|
|
|
|
export function methodID(name: string, types: Types): Buffer;
|
|
|
|
export function rawEncode(types: Types, values: Values): Buffer;
|
2018-04-14 22:21:33 +00:00
|
|
|
export function rawDecode(types: Types, data: string | Buffer): (Values)[];
|
|
|
|
export function simpleEncode(method: string, ...values: Values): Buffer;
|
|
|
|
export function simpleDecode(method: string, data: string | Buffer): (Values)[];
|
2018-03-07 23:36:05 +00:00
|
|
|
export function stringify(types: Types, values: Values): string;
|
|
|
|
export function solidityPack(types: Types, values: Values): Buffer;
|
|
|
|
export function soliditySHA3(types: Types, values: Values): Buffer;
|
|
|
|
export function soliditySHA256(types: Types, values: Values): Buffer;
|
|
|
|
export function solidityRIPEMD160(types: Types, values: Values): Buffer;
|
|
|
|
export function fromSerpent(sig: string): Types;
|
|
|
|
export function toSerpent(types: Types): string;
|
|
|
|
}
|