LoginRequest Class |
Namespace: Sfs2X.Requests
public class LoginRequest : BaseRequest
Name | Description | |
---|---|---|
LoginRequest(String) |
See LoginRequest(string, string, string, ISFSObject) constructor.
| |
LoginRequest(String, String) |
See LoginRequest(string, string, string, ISFSObject) constructor.
| |
LoginRequest(String, String, String) |
See LoginRequest(string, string, string, ISFSObject) constructor.
| |
LoginRequest(String, String, String, ISFSObject) |
Creates a new LoginRequest instance.
|
void SomeMethod() { sfs.AddEventListener(SFSEvent.LOGIN, OnLogin); sfs.AddEventListener(SFSEvent.LOGIN_ERROR, OnLoginError); // Login sfs.Send( new LoginRequest("FozzieTheBear", "", "SimpleChat") ); } void OnLogin(BaseEvent evt) { Console.WriteLine("Login successful!"); // .Net / Unity System.Diagnostics.Debug.WriteLine("Login successful!"); // UWP } void OnLoginError(BaseEvent evt) { Console.WriteLine("Login failure: " + (string)evt.Params["errorMessage"]); // .Net / Unity System.Diagnostics.Debug.WriteLine("Login failure: " + (string)evt.Params["errorMessage"]); // UWP }