import { StreamMessage, StreamPartID, ProxyDirection } from '@streamr/protocol'; import { Node, NodeOptions } from './Node'; import { NodeId } from '../identifiers'; export declare class NetworkNode extends Node { constructor(opts: NodeOptions); setExtraMetadata(metadata: Record): void; publish(streamMessage: StreamMessage): void | never; setProxies(streamPartId: StreamPartID, contactNodeIds: NodeId[], direction: ProxyDirection, getUserId: () => Promise, connectionCount?: number): Promise; addMessageListener(cb: (msg: StreamMessage) => void): void; removeMessageListener(cb: (msg: StreamMessage) => void): void; subscribe(streamPartId: StreamPartID): void; subscribeAndWaitForJoin(streamPartId: StreamPartID, timeout?: number): Promise; waitForJoinAndPublish(streamMessage: StreamMessage, timeout?: number): Promise; unsubscribe(streamPartId: StreamPartID): void; getNeighborsForStreamPart(streamPartId: StreamPartID): ReadonlyArray; hasStreamPart(streamPartId: StreamPartID): boolean; hasProxyConnection(streamPartId: StreamPartID, contactNodeId: NodeId, direction: ProxyDirection): boolean; getRtt(nodeId: NodeId): number | undefined; }