eventFetcher
Classes
EventFetcher
Fetches and parses blockchain logs
Methods
getEvents()
getEvents<TContract, TEventFilter>(
contractFactory: TypeChainContractFactory<TContract>,
topicGenerator: (t: TContract) => TEventFilter,
filter: object): Promise<FetchedEvent<TEventOf<TEventFilter>>[]>
Fetch logs and parse logs
Type parameters
Type parameter |
---|
TContract extends Contract <TContract > |
TEventFilter extends TypedEventFilter <TypedEvent <any , any >, TEventFilter > |
Parameters
Parameter | Type | Description |
---|---|---|
contractFactory | TypeChainContractFactory <TContract > | A contract factory for generating a contract of type TContract at the addr |
topicGenerator | (t : TContract ) => TEventFilter | Generator function for creating |
filter | object | Block and address filter parameters |
filter.address ? | string | - |
filter.fromBlock | BlockTag | - |
filter.toBlock | BlockTag | - |
Returns
Promise
<FetchedEvent
<TEventOf
<TEventFilter
>>[]>