Package top.focess.qq.api.net
Interface ServerMultiReceiver
-
- All Superinterfaces:
Receiver,ServerReceiver
- All Known Implementing Classes:
FocessUDPMultiReceiver
public interface ServerMultiReceiver extends ServerReceiver
The socket multi receiver for server.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default ClientgetClient(String name)Get the client by given nameList<Client>getClients(String name)Get the list of the clients with given namevoidsendPacket(int id, Packet packet)Send packet to the special client-
Methods inherited from interface top.focess.qq.api.net.ServerReceiver
isConnected, registerPackHandler, sendPacket
-
-
-
-
Method Detail
-
sendPacket
void sendPacket(int id, Packet packet)Send packet to the special client- Parameters:
id- the client idpacket- the packet
-
getClients
List<Client> getClients(String name)
Get the list of the clients with given name- Parameters:
name- the client name- Returns:
- the list of the clients with given name
-
getClient
@Nullable default Client getClient(String name)
Description copied from interface:ServerReceiverGet the client by given name- Specified by:
getClientin interfaceServerReceiver- Parameters:
name- the client name- Returns:
- the client
-
-