Package org.astrogrid.samp.hub
Class BasicClientSet
java.lang.Object
org.astrogrid.samp.hub.BasicClientSet
- All Implemented Interfaces:
ClientSet
Basic ClientSet implementation.
- Since:
- 20 Nov 2008
- Author:
- Mark Taylor
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidAdds a new client to the set.booleancontainsClient(HubClient client) Indicates whether a given client is currently a member of this set.Returns an array of all the currently contained clients.getFromPublicId(String publicId) Returns the client in the set corresponding to a given public ID.voidRemoves a client from the set.
-
Constructor Details
-
BasicClientSet
Constructor.- Parameters:
clientIdComparator- comparator for client IDs
-
-
Method Details
-
add
Description copied from interface:ClientSetAdds a new client to the set. -
remove
Description copied from interface:ClientSetRemoves a client from the set. -
getFromPublicId
Description copied from interface:ClientSetReturns the client in the set corresponding to a given public ID.- Specified by:
getFromPublicIdin interfaceClientSet- Parameters:
publicId- client public ID- Returns:
- client with id
publicIdif registered, or null
-
getClients
Description copied from interface:ClientSetReturns an array of all the currently contained clients.- Specified by:
getClientsin interfaceClientSet- Returns:
- client list
-
containsClient
Description copied from interface:ClientSetIndicates whether a given client is currently a member of this set.- Specified by:
containsClientin interfaceClientSet- Returns:
- true iff
clientis currently a member of this set
-