Show / Hide Table of Contents

    Class AccountHandler

    Handler in charge of taking care of any Account or portal related operations. Offers an easy to use access login and profile handling system.

    Inheritance
    System.Object
    BaseHandler
    AccountHandler
    Inherited Members
    BaseHandler.GetReusableApiRequest<T>()
    BaseHandler.GetHandlerStoragePath<T>()
    BaseHandler.JSON_FOLDER_NAME
    BaseHandler.GetHandlerJsonFolderPath<T>()
    BaseHandler.GetApiJsonFileName<T>()
    BaseHandler.GetApiJsonFileName<T>(UserProfile)
    BaseHandler.GetApiJsonFileFullPath<T, K>(UserProfile)
    BaseHandler.EncryptData(String)
    BaseHandler.DecryptData(String)
    BaseHandler.SaveJsonData<T, K>(AppearitionRequest<T>)
    BaseHandler.SaveJsonData<T, K>(AppearitionRequest<T>, UserProfile)
    BaseHandler.SaveJsonData<T, K>(AppearitionRequest<T>, String)
    BaseHandler.SaveJsonData<K>(String, String)
    BaseHandler.TryToFetchOfflineRequestContent<T, K>()
    BaseHandler.TryToFetchOfflineRequestContent<T, K>(UserProfile)
    BaseHandler.TryToFetchOfflineRequestContent<T, K>(String)
    BaseHandler.LoadJsonTextInFile<K>(String)
    BaseHandler.GetContentFromFileProcess(String, Action<Byte[]>)
    BaseHandler.SaveContentToFileProcess(Byte[], String, Action<Boolean>)
    BaseHandler.DeleteFileProcess(String, Action<Boolean>)
    BaseHandler.CopyFileToDestinationProcess(String, String, Action<Boolean>)
    BaseHandler.IsThereExistingMediaWithMatchingChecksum(String, String)
    BaseHandler.DownloadGenericFile(String, String, String, Boolean, Action<Byte[]>)
    BaseHandler.HandleSimpleOfflineApiContentLoadingWithCallback<T, K>(Action<T>, Action<EmsError>, Action<Boolean>)
    BaseHandler.HandleSimpleOnlineOnlyApiInternetCheck(Action<Boolean>, Action<EmsError>, Action<Boolean>)
    Namespace: Appearition.AccountAndAuthentication
    Assembly: Appearition.SDK.dll
    Syntax
    public sealed class AccountHandler : BaseHandler

    Methods

    GetProfileData(Action<ExtendedProfile>, Action<EmsError>, Action<Boolean>)

    Fetches all the information related to the profile of a logged in user.

    API Requirement: Anonymous Token.

    Declaration
    public static void GetProfileData(Action<ExtendedProfile> onSuccess = null, Action<EmsError> onFailure = null, Action<bool> onComplete = null)
    Parameters
    Type Name Description
    System.Action<ExtendedProfile> onSuccess

    Contains the profile data as on the EMS. Only called if the request is successful.

    System.Action<EmsError> onFailure

    Contains any error obtained during the request. Only called if the request has failed.

    System.Action<System.Boolean> onComplete

    Always called at the end of the request, defines whether the request was successful or not.

    GetProfileDataProcess(Action<ExtendedProfile>, Action<EmsError>, Action<Boolean>)

    Fetches all the information related to the profile of a logged in user.

    API Requirement: Anonymous Token.

    Declaration
    public static IEnumerator GetProfileDataProcess(Action<ExtendedProfile> onSuccess = null, Action<EmsError> onFailure = null, Action<bool> onComplete = null)
    Parameters
    Type Name Description
    System.Action<ExtendedProfile> onSuccess

    Contains the profile data as on the EMS. Only called if the request is successful.

    System.Action<EmsError> onFailure

    Contains any error obtained during the request. Only called if the request has failed.

    System.Action<System.Boolean> onComplete

    Always called at the end of the request, defines whether the request was successful or not.

    Returns
    Type Description
    System.Collections.IEnumerator

    GetRegisteredUserProfileData(Action<UserProfile>, Action<EmsError>, Action<Boolean>)

    Fetches all the information related to the profile of a logged in user targeting a FloAR-like EMS structure.

    API Requirement: Anonymous Token.

    Declaration
    public static void GetRegisteredUserProfileData(Action<UserProfile> onSuccess = null, Action<EmsError> onFailure = null, Action<bool> onComplete = null)
    Parameters
    Type Name Description
    System.Action<UserProfile> onSuccess

    Contains the user profile information as on the EMS. Only called if the request is successful.

    System.Action<EmsError> onFailure

    Contains any error obtained during the request. Only called if the request has failed.

    System.Action<System.Boolean> onComplete

    Always called at the end of the request, defines whether the request was successful or not.

    GetRegisteredUserProfileDataProcess(Action<UserProfile>, Action<EmsError>, Action<Boolean>)

    Fetches all the information related to the profile of a logged in user targeting a FloAR-like EMS structure.

    API Requirement: Anonymous Token.

    Declaration
    public static IEnumerator GetRegisteredUserProfileDataProcess(Action<UserProfile> onSuccess = null, Action<EmsError> onFailure = null, Action<bool> onComplete = null)
    Parameters
    Type Name Description
    System.Action<UserProfile> onSuccess

    Contains the user profile information as on the EMS. Only called if the request is successful.

    System.Action<EmsError> onFailure

    Contains any error obtained during the request. Only called if the request has failed.

    System.Action<System.Boolean> onComplete

    Always called at the end of the request, defines whether the request was successful or not.

    Returns
    Type Description
    System.Collections.IEnumerator

    Login(String, String, Action, Action<EmsError>, Action<Boolean>)

    Tries to login to the EMS with the credentials stored in the current profile. Do note that this is an optional step to access other requests.

    API Requirement: Anonymous Token.

    Declaration
    public static void Login(string username, string password, Action onSuccess = null, Action<EmsError> onFailure = null, Action<bool> onComplete = null)
    Parameters
    Type Name Description
    System.String username

    The username entered by the user.

    System.String password

    The password entered by the user.

    System.Action onSuccess

    Only called if the request is successful.

    System.Action<EmsError> onFailure

    Contains any error obtained during the request. Only called if the request has failed.

    System.Action<System.Boolean> onComplete

    Always called at the end of the request, defines whether the request was successful or not.

    LoginProcess(String, String, Action, Action<EmsError>, Action<Boolean>)

    Tries to login to the EMS with the credentials stored in the current profile. Do note that this is an optional step to access other requests.

    API Requirement: Anonymous Token.

    Declaration
    public static IEnumerator LoginProcess(string username, string password, Action onSuccess = null, Action<EmsError> onFailure = null, Action<bool> onComplete = null)
    Parameters
    Type Name Description
    System.String username

    The username entered by the user.

    System.String password

    The password entered by the user.

    System.Action onSuccess

    Only called if the request is successful.

    System.Action<EmsError> onFailure

    Contains any error obtained during the request. Only called if the request has failed.

    System.Action<System.Boolean> onComplete

    Always called at the end of the request, defines whether the request was successful or not.

    Returns
    Type Description
    System.Collections.IEnumerator

    Logout(Action, Action<EmsError>, Action<Boolean>)

    Using the information stored in the current user and its session token, ends the current session with the EMS and resets token to its global one.

    API Requirement: Session Token.

    Declaration
    public static void Logout(Action onSuccess = null, Action<EmsError> onFailure = null, Action<bool> onComplete = null)
    Parameters
    Type Name Description
    System.Action onSuccess

    Only called if the request is successful.

    System.Action<EmsError> onFailure

    Contains any error obtained during the request. Only called if the request has failed.

    System.Action<System.Boolean> onComplete

    Always called at the end of the request, defines whether the request was successful or not.

    LogoutProcess(Action, Action<EmsError>, Action<Boolean>)

    Using the information stored in the current user and its session token, ends the current session with the EMS and resets token to its global one.

    API Requirement: Session Token.

    Declaration
    public static IEnumerator LogoutProcess(Action onSuccess = null, Action<EmsError> onFailure = null, Action<bool> onComplete = null)
    Parameters
    Type Name Description
    System.Action onSuccess

    Only called if the request is successful.

    System.Action<EmsError> onFailure

    Contains any error obtained during the request. Only called if the request has failed.

    System.Action<System.Boolean> onComplete

    Always called at the end of the request, defines whether the request was successful or not.

    Returns
    Type Description
    System.Collections.IEnumerator

    RegisterDevice(String, String, Action, Action<EmsError>, Action<Boolean>)

    A login method targeting a FloAR-like EMS structure.

    API Requirement: Anonymous Token.

    Declaration
    public static void RegisterDevice(string username, string password, Action onSuccess = null, Action<EmsError> onFailure = null, Action<bool> onComplete = null)
    Parameters
    Type Name Description
    System.String username

    The username entered by the user.

    System.String password

    The password entered by the user.

    System.Action onSuccess

    Only called if the request is successful.

    System.Action<EmsError> onFailure

    Contains any error obtained during the request. Only called if the request has failed.

    System.Action<System.Boolean> onComplete

    Always called at the end of the request, defines whether the request was successful or not.

    RegisterDeviceProcess(String, String, Action, Action<EmsError>, Action<Boolean>)

    A login method targeting a FloAR-like EMS structure.

    API Requirement: Anonymous Token.

    Declaration
    public static IEnumerator RegisterDeviceProcess(string username, string password, Action onSuccess = null, Action<EmsError> onFailure = null, Action<bool> onComplete = null)
    Parameters
    Type Name Description
    System.String username

    The username entered by the user.

    System.String password

    The password entered by the user.

    System.Action onSuccess

    Only called if the request is successful.

    System.Action<EmsError> onFailure

    Contains any error obtained during the request. Only called if the request has failed.

    System.Action<System.Boolean> onComplete

    Always called at the end of the request, defines whether the request was successful or not.

    Returns
    Type Description
    System.Collections.IEnumerator

    UpdateProfileSettings(Profile, Action, Action<EmsError>, Action<Boolean>)

    Updates the information of the logged in user. Should be used to update name, email or any custom attribute. If wanting to remove an attribute, do set said attribute doDeleteAttribute to true.

    API Requirement: Anonymous Token.

    Declaration
    public static void UpdateProfileSettings(Profile profileData, Action onSuccess = null, Action<EmsError> onFailure = null, Action<bool> onComplete = null)
    Parameters
    Type Name Description
    Profile profileData

    The user's profile as on the EMS. Can be fetched using GetProfileData.

    System.Action onSuccess

    Only called if the request is successful.

    System.Action<EmsError> onFailure

    Contains any error obtained during the request. Only called if the request has failed.

    System.Action<System.Boolean> onComplete

    Always called at the end of the request, defines whether the request was successful or not.

    UpdateProfileSettingsProcess(Profile, Action, Action<EmsError>, Action<Boolean>)

    Updates the information of the logged in user. Should be used to update name, email or any custom attribute. If wanting to remove an attribute, do set said attribute doDeleteAttribute to true.

    API Requirement: Anonymous Token.

    Declaration
    public static IEnumerator UpdateProfileSettingsProcess(Profile profileData, Action onSuccess = null, Action<EmsError> onFailure = null, Action<bool> onComplete = null)
    Parameters
    Type Name Description
    Profile profileData

    The user's profile as on the EMS. Can be fetched using GetProfileData.

    System.Action onSuccess

    Only called if the request is successful.

    System.Action<EmsError> onFailure

    Contains any error obtained during the request. Only called if the request has failed.

    System.Action<System.Boolean> onComplete

    Always called at the end of the request, defines whether the request was successful or not.

    Returns
    Type Description
    System.Collections.IEnumerator

    Extension Methods

    ObjectExtension.ToStream(Object)
    Back to top Appearition SDK for Unity API