@armada/sdk / index / RpcEventSource
Class: RpcEventSource
Defined in: src/sync/event-source.ts:14
Default source: ranged getLogs over [fromBlock, toBlock], decoded to the native event shape. Always covers the full requested range (syncedThroughBlock === toBlock), so it is both the standalone sync path and the tail/verification fallback for the indexer source.
Implements
Constructors
Constructor
new RpcEventSource(
getLogs,maxRange?):RpcEventSource
Defined in: src/sync/event-source.ts:15
Parameters
getLogs
maxRange?
number
Returns
RpcEventSource
Methods
getEvents()
getEvents(
fromBlock,toBlock,onProgress?):Promise<EventBatch>
Defined in: src/sync/event-source.ts:20
onProgress (when supplied) is called with the highest block covered as the fetch chunks the range.
Parameters
fromBlock
number
toBlock
number
onProgress?
(coveredThroughBlock) => void
Returns
Promise<EventBatch>