Improve log events types
This commit is contained in:
parent
73d13d61a7
commit
6eb5411029
13
packages/web3-typescript-typings/index.d.ts
vendored
13
packages/web3-typescript-typings/index.d.ts
vendored
@ -114,15 +114,22 @@ declare module 'web3' {
|
|||||||
|
|
||||||
type LogTopic = null|string|string[];
|
type LogTopic = null|string|string[];
|
||||||
|
|
||||||
interface SolidityEvent<A> {
|
interface DecodedLogEntry<A> extends LogEntry {
|
||||||
event: string;
|
event: string;
|
||||||
address: string;
|
|
||||||
args: A;
|
args: A;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
interface DecodedLogEntryEvent<A> extends DecodedLogEntry<A> {
|
||||||
|
removed: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
interface LogEntryEvent extends LogEntry {
|
||||||
|
removed: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
interface FilterResult {
|
interface FilterResult {
|
||||||
get(callback: () => void): void;
|
get(callback: () => void): void;
|
||||||
watch<A>(callback: (err: Error, result: SolidityEvent<A>) => void): void;
|
watch(callback: (err: Error, result: LogEntryEvent) => void): void;
|
||||||
stopWatching(callback: () => void): void;
|
stopWatching(callback: () => void): void;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user