blob: 257e7823b4124d0feccc6ce283449cb662f869ba (
plain) (
blame)
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
|
// tslint:disable:completed-docs
declare module 'solc' {
import * as Web3 from 'web3';
export interface ContractCompilationResult {
srcmap: string;
srcmapRuntime: string;
bytecode: string;
runtimeBytecode: string;
interface: string;
}
export interface CompilationResult {
errors: string[];
contracts: {
[contractIdentifier: string]: ContractCompilationResult;
};
sources: {
[sourceName: string]: {
AST: any;
};
};
sourceList: string[];
}
export interface ImportContents {
contents: string;
}
export interface InputSources {
sources: {
[fileName: string]: string;
};
}
export interface SolcInstance {
compile(
sources: InputSources,
optimizerEnabled: number,
findImports: (importPath: string) => ImportContents,
): CompilationResult;
}
export function loadRemoteVersion(versionName: string, cb: (err: Error | null, res?: SolcInstance) => void): void;
export function setupMethods(solcBin: any): SolcInstance;
}
declare module 'web3-eth-abi' {
export function encodeParameters(typesArray: string[], parameters: any[]): string;
}
|