import { Disposable } from "@codesandbox/pitcher-common"; import type { ClientJSON } from "@codesandbox/pitcher-protocol/dist/src/messages/client"; import { States } from "class-states"; import type { ChannelData, ChannelMessageEvent, FollowersState, FollowingState, IFollowChannel } from "../../../interface/clients/IChannelClient"; import type { PitcherMessageHandler } from "../../PitcherMessageHandler"; import { Channel } from "./Channel"; /** * Used to allow others to follow this client and follow other clients */ export declare class FollowChannel extends Disposable implements IFollowChannel { private name; private messageHandler; private currentClient; private hostChannel; onFollowerJoin: Channel["onSubscribe"]; onFollowerLeave: Channel["onUnsubscribe"]; private followChannel?; private onFollowMessageEmitter; onFollowMessage: import("@codesandbox/pitcher-common").Event>; private onUnfollowMessageEmitter; onUnfollow: import("@codesandbox/pitcher-common").Event; state: { following: States; followers: States; }; constructor(name: string, messageHandler: PitcherMessageHandler, currentClient: ClientJSON); sendAllFollowers(message: T): Promise<{ clients: string[]; }> | undefined; sendFollower(clientId: string, message: T): Promise<{ clients: string[]; }> | undefined; follow(clientId: string): void; unfollow(): void; resync(): void; } //# sourceMappingURL=FollowChannel.d.ts.map