import StaticChannel from '../StaticChannel'; import Socket from '../../Socket'; import { ComplexTypesOption } from 'ziron-worker'; export default class StaticChannelContainer { private readonly _channels; private readonly _count; constructor(channels: StaticChannel[]); get channels(): StaticChannel[]; /** * **Not override this method.** * Publish into this channel. * @param event * @param data * @param options * The publisher sid indicates the socket sid that publishes the data. * If you provide one the published data will not send to the publisher socket. */ publish(event: string, data: any, options?: ComplexTypesOption & { publisherSid?: string; }): void; /** * The close function will close the Channel for every client on every server. * You optionally can provide a code or any other information for the client. * Usually, the close function is used when the data is completely deleted from the system. * For example, a chat that doesn't exist anymore. * @param code * @param metadata * @param forEveryServer * @return The returned promise is resolved when * the close is fully processed on the current server. */ close(code?: number | string, metadata?: any, forEveryServer?: boolean): Promise; /** * **Not override this method.** * Kicks out a socket from this channel. * @param socket * @param code * @param metadata */ kickOut(socket: Socket, code?: number | string, metadata?: any): void; }