sfs2x.client.entities.managers
Interface IUserManager

All Known Implementing Classes:
SFSUserManager

public interface IUserManager

The IUserManager interface defines all the methods and properties exposed by the client-side manager of the SmartFoxServer User entities.

In the SmartFoxServer 2X client API this interface is implemented by the SFSUserManager class. Read the class description for additional informations.

See Also:
SFSUserManager

Method Summary
 void addUser(User user)
          * API internal usage only *
 void clearAll()
          * API internal usage only *
 boolean containsUser(User user)
          Indicates whether a user exists in the local users list or not.
 boolean containsUserId(int userId)
          Indicates whether a user exists in the local users list or not from the id.
 boolean containsUserName(java.lang.String userName)
          Indicates whether a user exists in the local users list or not from the name.
 ISmartFox getSmartFox()
          * API internal usage only *
 User getUserById(int userId)
          Retrieves a User object from its id property.
 User getUserByName(java.lang.String userName)
          Retrieves a User object from its name property.
 int getUserCount()
          Returns the total number of users in the local users list.
 java.util.List<User> getUserList()
          Get the whole list of users inside the Rooms joined by the client.
 void removeUser(User user)
          * API internal usage only *
 void removeUserById(int id)
          * API internal usage only *
 

Method Detail

containsUserName

boolean containsUserName(java.lang.String userName)
Indicates whether a user exists in the local users list or not from the name.

Parameters:
userName - The name of the user whose presence in the users list is to be tested.
Returns:
true if the passed user exists in the users list.
See Also:
User.getName()

containsUserId

boolean containsUserId(int userId)
Indicates whether a user exists in the local users list or not from the id.

Parameters:
userId - The id of the user whose presence in the users list is to be tested.
Returns:
true if the passed user exists in the users list.
See Also:
User.getId()

containsUser

boolean containsUser(User user)
Indicates whether a user exists in the local users list or not.

Parameters:
user - The User object representing the user whose presence in the users list is to be tested.
Returns:
true if the passed user exists in the users list.

getUserByName

User getUserByName(java.lang.String userName)
Retrieves a User object from its name property.

Parameters:
userName - The name of the user to be found.
Returns:
The User object representing the user, or null if no user with the passed name exists in the local users list.
See Also:
User.getName(), getUserById(int)

getUserById

User getUserById(int userId)
Retrieves a User object from its id property.

Parameters:
userId - The id of the user to be found.
Returns:
The User object representing the user, or null if no user with the passed id exists in the local users list.
See Also:
User.getId(), getUserByName(java.lang.String)

addUser

void addUser(User user)
* API internal usage only *


removeUser

void removeUser(User user)
* API internal usage only *


removeUserById

void removeUserById(int id)
* API internal usage only *


getUserCount

int getUserCount()
Returns the total number of users in the local users list.


getUserList

java.util.List<User> getUserList()
Get the whole list of users inside the Rooms joined by the client.

Returns:
The list of User objects representing the users in the local users list.

getSmartFox

ISmartFox getSmartFox()
* API internal usage only *


clearAll

void clearAll()
* API internal usage only *