import { EventTS } from '@jaenster/events';
import { FiFo } from '@jaenster/queues';
import type { ChannelClient } from "./client";
export interface Channel<T> {
    on<S = this>(this: S, on: 'data', cb: (this: S, data: T) => any, s?: object): any;
    in(...t: T[]): void;
}
export declare class Channel<T> extends EventTS {
    protected queue: FiFo<T>;
    constructor();
    static factory<T>(this: {
        new (): Channel<[ChannelClient<T>, T]>;
    }): Channel<[ChannelClient<T>, T]>;
}
