STWAccountSettings

open class STWAccountSettings

This class represent all settings related to the account.

Functions

Link copied to clipboard
open fun deleteUserPicture(@NonNull context: Context, @Nullable callback: STWOperationCallback<STWAccountSettingsError>)
Call this method to delete the user profile picture
Link copied to clipboard
open fun dispatchAccountInfoChanged()
Link copied to clipboard
open fun exportSettings(@NonNull context: Context, @Nullable callback: STWExportSettingsCallback)
Method to export settings in order to share them with other contacts.
Link copied to clipboard
open fun getAdminEmail(): String
The email of the administrator to be contacted in case of issues (can be an empty string)
Link copied to clipboard
open fun getAdminName(): String
The name of the administrator to be contacted in case of issues (can be an empty string)
Link copied to clipboard
open fun getApplicationLink(@NonNull context: Context): String
Calle this method to retrieve the application link
Link copied to clipboard
open fun getAttachmentSize(): Int
The total size in bytes of message attachments.
Link copied to clipboard
open fun getCompanyId(@NonNull context: Context): String
Call this method to get the CompanyID
Link copied to clipboard
open fun getFillPercentage(): Int
The used storage in percentage.
Link copied to clipboard
open fun getInstance(): STWAccountSettings
Account settings instance.
Link copied to clipboard
open fun getMaxPictureSize(@NonNull context: Context): Int
The maximum size of subscriber picture in kilo bytes who can be uploaded by user.
Link copied to clipboard
open fun getMaxSizeForQuota(): Int
The maximum allowed storage in bytes.
Link copied to clipboard
open fun getOrganizationLabel(@NonNull context: Context): String
Link copied to clipboard
open fun getProcessesSize(): Int
The total size in bytes of processes.
Link copied to clipboard
open fun getServerName(@NonNull context: Context): String
Call this method to get the human friendly name of the SIP server.
Link copied to clipboard
open fun getThresholdsAlertValue(): Int
The percentage after which the alert notifications must be displayed to the user
Link copied to clipboard
open fun getThresholdsWaringValue(): Int
The percentage after which the warning notifications must be displayed to the user
Link copied to clipboard
open fun getUsedSizeForQuota(): Int
The used storage in bytes.
Link copied to clipboard
open fun getUserAliasStatus(@NonNull context: Context): Long
Call this method to get the status of alias
Link copied to clipboard
open fun getUserAvailability(@NonNull context: Context): Long
Call this method to retrieve the User Availability status
Link copied to clipboard
open fun getUserCustomAlias(@NonNull context: Context): String
Link copied to clipboard
open fun getUserCustomStatus(@NonNull context: Context): String
Link copied to clipboard
open fun getUserDisplayName(@NonNull context: Context): String
Get get display name of the current user
Link copied to clipboard
open fun getUserPhone(@NonNull context: Context): PhoneItem
Get the PhoneItem corresponding to the current user account
Link copied to clipboard
open fun importSettings(    @NonNull context: Context,     @NonNull attachmentId: String,     @Nullable callback: ImportSettingsCallBack)
open fun importSettings(    @NonNull context: Context,     @NonNull path: String,     @Nullable callback: STWImportSettingsCallback)
Method to import and apply settings received from other contacts.
Link copied to clipboard
open fun isAliasModificationAllowed(@NonNull context: Context): Boolean
Call this method to check if the modification of alias from client is allowed or not
Link copied to clipboard
open fun isCloudStorageEnabled(): Boolean
Call this method to check if the CloudStorage is enabled.
Link copied to clipboard
open fun isDisplayDisconnectedUsersAllowed(@NonNull context: Context): Boolean
Call this method to check if display diconnected users when not reachable is allowed or not
Link copied to clipboard
open fun isMessageAttachmentsCountedInStorage(): Boolean
Whether the attachments are counted in the storage quota or not
Link copied to clipboard
open fun isOperationalStatusAllowed(@NonNull context: Context): Boolean
Method to check if the OperationalStatus feature is enabled ot not
Link copied to clipboard
open fun isProcessesCountedInStorage(): Boolean
Whether the processes are counted in the storage quota
Link copied to clipboard
open fun isProfileModificationsFromClientAllowed(@NonNull context: Context): Boolean
Call this method to check whether the user can modified his profile status/picture or not
Link copied to clipboard
open fun isUserAliasAllowed(@NonNull context: Context): Boolean
Call this method to check if Alias feature is allowed or not
Link copied to clipboard
open fun isUserAvailabilityAllowed(@NonNull context: Context): Boolean
Whether the subscriber user availability feature is enabled in backend or not
Link copied to clipboard
open fun loadCompanyLogo(@NonNull imageView: ImageView, @Nullable callback: STWOperationCallback<STWAccountSettingsError>)
Call this method to retrieve the current company logo
Link copied to clipboard
open fun loadUserPicture(    @NonNull context: Context,     @NonNull lifecycle: Lifecycle,     @NonNull imageView: ImageView,     @Nullable defaultContactIconResources: DefaultContactIconResources)
Try to load asynchronously the user picture in the imageView.
Link copied to clipboard
open fun registerAccountChanged(@NonNull listener: STWAccountChanged)
Register to all events related to the account
Link copied to clipboard
open fun registerCompanyInformationChanged(@NonNull listener: STWCompanyInformationChanged)
Register to all events related to the company information
open fun registerForDisconnectedUserFeatureChanged(@NonNull disconnectedUserFeatureChangedListener: STWDisconnectedUserFeatureChangedListener)
Call this method to register for events related to connected user feature
Link copied to clipboard
open fun registerToAliasEvents(@NonNull aliasCallback: STWUserCustomAliasCallback)
Call this method to register for events related to user alias feature
Link copied to clipboard
open fun registerToAllowUserAvailabilityEvents(@NonNull allowUserAvailabilityCallback: STWAllowUserAvailabilityListener)
Call this method to register for events related to the user availability allowed or not.
Link copied to clipboard
open fun registerToCloudStorageEvents(@NonNull cloudStorageCallback: STWCloudStorageCallback)
Listen to the cloud storage events
Link copied to clipboard
open fun registerToDisplayNameOrderEvents(@NonNull displayNameOrderCallback: STWDisplayNameOrderListener)
Listen to the display name order events
Link copied to clipboard
open fun registerToOperationalStatusEvents(@NonNull operationStatusCallback: STWOperationStatusListener)
Listen to the operational status events
Link copied to clipboard
open fun registerToRoleIconEvents(@NonNull roleIconCallback: STWRoleIconListener)
Listen to the role icon events
Link copied to clipboard
open fun registerToServerNameChanges(@NonNull serverNameCallback: STWServerNameCallback)
Listen to the server name changes when the client switches between servers
Link copied to clipboard
open fun registerToUserAvailability(@NonNull listener: STWUserAvailabilityListener)
Call this method to register to the changing of the User Availability status.
Link copied to clipboard
open fun registerToUserCustomStatus(@NonNull listener: STWUserCustomStatusCallback)
Call this method to register to the changing of the User custom status.
Link copied to clipboard
open fun requestForCloudStorageQuotaStatus(@NonNull context: Context)
Call this method to ask for the cloud quota storage values from the backend.
Link copied to clipboard
open fun resetSettings(@NonNull context: Context, @NonNull operationCallback: STWOperationCallback<STWAccountSettingsError>)
Call this method to reset all settings related to the account.
Link copied to clipboard
open fun unregisterAccountChanged(@NonNull listener: STWAccountChanged)
Unregister a previously registered account information listener
Link copied to clipboard
open fun unregisterCompanyInformationChanged(@NonNull listener: STWCompanyInformationChanged)
Unregister a previously registered company information listener
open fun unregisterForDisconnectedUserFeatureChanged(@NonNull disconnectedUserFeatureChangedListener: STWDisconnectedUserFeatureChangedListener)
Call this method to unregister from events related to connected user feature
Link copied to clipboard
open fun unregisterFromAliasEvents(@NonNull aliasCallback: STWUserCustomAliasCallback)
Call this method to unregister from events related to user alias feature
open fun unregisterFromAllowUserAvailabilityEvents(@NonNull allowUserAvailabilityCallback: STWAllowUserAvailabilityListener)
Call this method to register for events related to the user availability allowed or not.
Link copied to clipboard
open fun unregisterFromDisplayNameOrderEvents(@NonNull displayNameOrderCallback: STWDisplayNameOrderListener)
Stop listening to the display name order events
Link copied to clipboard
open fun unregisterFromOperationalStatusEvents(@NonNull operationStatusCallback: STWOperationStatusListener)
Stop listening to the operational status events
Link copied to clipboard
open fun unregisterFromRoleIconEvents(@NonNull roleIconCallback: STWRoleIconListener)
Stop listening to the role icon events
Link copied to clipboard
open fun unregisterServerNameChanges(@NonNull serverNameCallback: STWServerNameCallback)
Stop listening to the server name changes when the client switches between servers
Link copied to clipboard
open fun unregisterToCloudStorageEvents(@NonNull cloudStorageCallback: STWCloudStorageCallback)
Stop listening to the cloud storage events
Link copied to clipboard
open fun unregisterToUserAvailability(@NonNull listener: STWUserAvailabilityListener)
Call this method to unregister from the changign of the User Availability status.
Link copied to clipboard
open fun unregisterToUserCustomStatus(@NonNull listener: STWUserCustomStatusCallback)
Call this method to unregister from the changing of the User custom status.
Link copied to clipboard
open fun updateDisplayNameOrder(    @NonNull context: Context,     @NonNull displayNameOrderValue: String,     @Nullable callback: STWOperationCallback<STWAccountSettingsError>)
Call this method to change the display name order
Link copied to clipboard
open fun updateUserAvailability(    @NonNull context: Context,     userAvailabilityValue: Int,     @Nullable callback: STWOperationCallback<STWAccountSettingsError>)
Call this method to change the user availability
Link copied to clipboard
open fun updateUserCustomAlias(    @NonNull context: Context,     @NonNull newCustomAlias: String,     @Nullable callBack: STWOperationCallback<STWAccountSettingsError>)
Call this method to update the user custom alias
Link copied to clipboard
open fun updateUserCustomStatus(    @NonNull context: Context,     @NonNull newCustomStatus: String,     @Nullable callBack: STWOperationCallback<STWAccountSettingsError>)
Call this method to update the user custom status
Link copied to clipboard
open fun updateUserOperationalStatus(    @NonNull context: Context,     operationalStatusId: Int,     @Nullable callBack: STWOperationCallback<STWAccountSettingsError>)
Update and synchronize user operational status
Link copied to clipboard
open fun uploadUserPicture(    @NonNull context: Context,     @NonNull file: File,     @Nullable callback: STWOperationCallback<STWAccountSettingsError>)
Call this method to update the user profile picture