import { Namespace } from '../namespace' ; import { PresenceMemberInfo } from '../channels/presence-channel-manager' ; import { WebSocket } from 'uWebSockets.js' ; const Discover = require ( 'node-discover' ) ; export interface AdapterInterface { /**
     * The app connections storage class to manage connections.
     */ namespaces ? : Map < string , Namespace > ; /**
     * The list of nodes in the current private network.
     */ driver ? : AdapterInterface ; /**
     * Get the app namespace.
     */ getNamespace ( appId ) : Namespace ; /**
     * Get all namespaces.
     */ getNamespaces ( ) : Map < string , Namespace > ; /**
     * Send a message to a namespace and channel.
     */ send ( appId , channel , data , exceptingId ? ) : any ; /**
     * Clear the local namespaces.
     */ clear ( namespaceId ? , closeConnections ? ) : Promise < void > ; /**
     * Get all sockets from the namespace.
     */ getSockets ( appId , onlyLocal ? ) : Promise < Map < string , WebSocket > > ; /**
     * Get total sockets count.
     */ getSocketsCount ( appId , onlyLocal ? ) : Promise < number > ; /**
     * Get the list of channels with the websocket IDs.
     */ getChannels ( appId , onlyLocal ? ) : Promise < Map < string , Set < string > > > ; /**
     * Get all the channel sockets associated with a namespace.
     */ getChannelSockets ( appId , channel , onlyLocal ? ) : Promise < Map < string , WebSocket > > ; /**
     * Get a given channel's total sockets count.
     */ getChannelSocketsCount ( appId , channel , onlyLocal ? ) : Promise < number > ; /**
     * Get a given presence channel's members.
     */ getChannelMembers ( appId , channel , onlyLocal ? ) : Promise < Map < string , PresenceMemberInfo > > ; /**
     * Get a given presence channel's members count
     */ getChannelMembersCount ( appId , channel , onlyLocal ? ) : Promise < number > ; /**
     * Check if a given connection ID exists in a channel.
     */ isInChannel ( appId , channel , wsId , onlyLocal ? ) : Promise < boolean > ; }