/// import { EventEmitter } from 'events'; import Connection, { Options as ConnectionOptions } from '../core/Connection'; import Http, { Track, TrackInfo, TrackResponse } from '../core/Http'; import PlayerStore from '../core/PlayerStore'; export interface VoiceStateUpdate { guild_id: string; channel_id?: string; user_id: string; session_id: string; deaf?: boolean; mute?: boolean; self_deaf?: boolean; self_mute?: boolean; suppress?: boolean; } export interface VoiceServerUpdate { guild_id: string; token: string; endpoint: string; } export interface BaseNodeOptions { password: string; userID: string; shardCount?: number; hosts?: { rest?: string; ws?: string | { url: string; options: ConnectionOptions; }; }; host?: string; } export default abstract class BaseNode extends EventEmitter { abstract send: (guildID: string, packet: any) => Promise; password: string; userID: string; shardCount?: number; connection?: Connection; players: PlayerStore; http?: Http; voiceStates: Map; voiceServers: Map; private _expectingConnection; constructor({ password, userID, shardCount, hosts, host }: BaseNodeOptions); get connected(): boolean; load(identifier: string): Promise; decode(track: string): Promise; decode(tracks: string[]): Promise; voiceStateUpdate(packet: VoiceStateUpdate): Promise; voiceServerUpdate(packet: VoiceServerUpdate): Promise; disconnect(code?: number, data?: string): Promise; destroy(code?: number, data?: string): Promise; private _tryConnection; }