SFS2X Objective-C API  1.7.13
iOS / macOS / tvOS
SFSUserManager Class Reference

#import <SFSUserManager.h>

Inherits NSObject, and <IUserManager>.

Inherited by SFSGlobalUserManager.

Instance Methods

(id) - initWithSfs:
 
(void) - _addUser:
 
(BOOL) - containsUserName:
 
(BOOL) - containsUserId:
 
(BOOL) - containsUser:
 
(id< User >) - getUserByName:
 
(id< User >) - getUserById:
 
(NSArray *) - getUserList
 
(void) - replaceAll:
 

Protected Attributes

Logger * _log
 
__weak SmartFox2XClient_smartFox
 
NSObject * _globalLock
 

Properties

NSInteger userCount
 

Detailed Description

Manages the local Users.

The client side API only see the Users that are joined in the same Rooms of the current User.

Method Documentation

◆ containsUser:

- (BOOL) containsUser: (id <User>)  user

Checks if a specific User object exists in the local User list

◆ containsUserId:

- (BOOL) containsUserId: (NSInteger)  userId

Checks if a specific User id exists in the local User list

◆ containsUserName:

- (BOOL) containsUserName: (NSString *)  userName

Checks if a specific User name exists in the local User list

◆ getUserById:

- (id< User >) getUserById: (NSInteger)  userId

Get a User object from its id

◆ getUserByName:

- (id< User >) getUserByName: (NSString *)  userName

Get a User object from its name

◆ getUserList

- (NSArray *) getUserList

Get the full list of Users

Property Documentation

◆ userCount

- (NSInteger) userCount
readatomicassign

Get the total number of Users