import { StreamID, StreamMessage, StreamPartID } from '@streamr/protocol'; import { EthereumAddress } from '@streamr/utils'; import { StrictStreamrClientConfig } from '../Config'; import { StorageNodeRegistry } from '../registry/StorageNodeRegistry'; import { StreamStorageRegistry } from '../registry/StreamStorageRegistry'; import { LoggerFactory } from '../utils/LoggerFactory'; import { PushPipeline } from '../utils/PushPipeline'; import { MessagePipelineFactory } from './MessagePipelineFactory'; export interface ResendRef { timestamp: number | Date | string; sequenceNumber?: number; } /** * Resend the latest "n" messages. */ export interface ResendLastOptions { last: number; } /** * Resend messages starting from a given point in time. */ export interface ResendFromOptions { from: ResendRef; publisherId?: string; } /** * Resend messages between two points in time. */ export interface ResendRangeOptions { from: ResendRef; to: ResendRef; msgChainId?: string; publisherId?: string; } /** * The supported resend types. */ export type ResendOptions = ResendLastOptions | ResendFromOptions | ResendRangeOptions; export type ResendType = 'last' | 'from' | 'range'; export declare class Resends { private readonly streamStorageRegistry; private readonly storageNodeRegistry; private readonly messagePipelineFactory; private readonly config; private readonly logger; constructor(streamStorageRegistry: StreamStorageRegistry, storageNodeRegistry: StorageNodeRegistry, messagePipelineFactory: MessagePipelineFactory, config: StrictStreamrClientConfig, loggerFactory: LoggerFactory); resend(streamPartId: StreamPartID, options: ResendOptions & { raw?: boolean; }, getStorageNodes?: (streamId: StreamID) => Promise, abortSignal?: AbortSignal): Promise>; private fetchStream; }