The User class stores the properties of each user.
This class is used internally by the SmartFoxClient class; also, User objects are returned by various methods and events of the SmartFoxServer API.
This class is used internally by the SmartFoxClient class; also, User objects are returned by various methods and events of the SmartFoxServer API.

C# | Visual Basic | Visual C++ |
public class User
Public Class User
public ref class User

All Members | Constructors | Methods | |||
Icon | Member | Description |
---|---|---|
![]() | User(Int32, String) |
User constructor.
|
![]() | Equals(Object) | (Inherited from Object.) |
![]() | Finalize()()() |
Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.
(Inherited from Object.) |
![]() | GetHashCode()()() |
Serves as a hash function for a particular type.
(Inherited from Object.) |
![]() | GetId()()() |
Get the id of the user.
|
![]() | GetName()()() |
Get the name of the user.
|
![]() | GetPlayerId()()() |
Retrieve the player id of the user. The user must be a player inside a game room for this method to work properly. This id is 1-based (player 1, player 2, etc.), but if the user is a spectator its value is -1. |
![]() | GetType()()() |
Gets the Type of the current instance.
(Inherited from Object.) |
![]() | GetVariable(String) |
Retrieve a User Variable.
|
![]() | GetVariables()()() |
Retrieve the list of all User Variables.
|
![]() | IsModerator()()() |
A boolean flag indicating if the user is a Moderator in the current zone.
|
![]() | IsSpectator()()() |
A boolean flag indicating if the user is a spectator in the current room.
|
![]() | MemberwiseClone()()() |
Creates a shallow copy of the current Object.
(Inherited from Object.) |
![]() | SetIsSpectator(Boolean) |
Set the IsSpectator()()() property.
|
![]() | SetModerator(Boolean) |
Set the IsModerator()()() property.
|
![]() | SetPlayerId(Int32) |
Set the playerId property.
|
![]() | SetVariables(Dictionary<(Of <(String, Object>)>)) |
Set the User Variables.
|
![]() | ToString()()() | (Inherited from Object.) |

NOTE:
in the provided examples, user always indicates a User instance.
Version:
1.0.0
Author:
Thomas Hentschel Lund
http://www.fullcontrol.dk
sfs-api@fullcontrol.dk
http://www.smartfoxserver.com
http://www.gotoandplay.it

Object | |
![]() | User |