import { GenericMiddleware, ILoggerService, IStoreService, Opcode, ProtocolName, ProtocolParam, ProtocolParams, ProtocolEventMessage, NetworkContexts, ProtocolMessage } from "@connext/types"; import { MiddlewareContainer } from "./middleware"; import { StateChannel, AppInstance } from "../models"; import { RpcRouter } from "../rpc-router"; export declare class ProtocolRunner { readonly networks: NetworkContexts; readonly store: IStoreService; readonly log: ILoggerService; middlewares: MiddlewareContainer; constructor(networks: NetworkContexts, store: IStoreService, log: ILoggerService); register(scope: Opcode, method: GenericMiddleware): void; runProtocolWithMessage(router: RpcRouter, msg: ProtocolMessage, preProtocolStateChannel?: StateChannel): Promise<{ channel: StateChannel; data: any; appContext: AppInstance; protocolMeta: any; }>; initiateProtocol(router: RpcRouter, protocolName: ProtocolName, params: ProtocolParam, preProtocolStateChannel?: StateChannel): Promise<{ channel: StateChannel; data: any; appContext: AppInstance; protocolMeta: any; }>; runSetupProtocol(router: RpcRouter, params: ProtocolParams.Setup): Promise<{ channel: StateChannel; data: any; appContext: AppInstance; protocolMeta: any; }>; private runProtocol; } export declare const getOutgoingEventFailureDataFromProtocol: (protocol: ProtocolName, params: ProtocolParam, error: Error) => ProtocolEventMessage; export declare const emitOutgoingMessage: (router: RpcRouter, msg: ProtocolEventMessage) => Promise; //# sourceMappingURL=protocol-runner.d.ts.map