Class PresenceConfiguration
- java.lang.Object
-
- com.avaya.clientservices.presence.PresenceConfiguration
-
public class PresenceConfiguration extends java.lang.ObjectUser configuration information for the presence service. This class provides configuration and preference data for the presence service features.
-
-
Constructor Summary
Constructors Constructor Description PresenceConfiguration()A default constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description longgetAwayTimeout()The user inactivity timeout period in milliseconds.java.lang.StringgetServerAddress()Configured presence server address.booleanisEnabled()Indicates whether the presence service is enabled.booleanisPresenceUpdateInBackgroundEnabled()Indicates whether contact presence updates should be monitored and reported even when mobile platform application is not visible.booleanisSendAllCallsOnDoNotDisturb()Indicates a link between "Do Not Disturb" presence state and "Send All Calls" call service feature.voidsetAwayTimeout(long awayTimeout)Sets the timeout for the user inactivity timer.voidsetEnabled(boolean enabled)Enables or disables the presence service.voidsetPresenceUpdateInBackgroundEnabled(boolean presenceUpdateInBackgroundEnabled)Enables or disables contact presence monitoring when mobile platform application is not visible.voidsetSendAllCallsOnDoNotDisturb(boolean sendAllCallsOnDoNotDisturb)Sets a link between "Do Not Disturb" presence state and "Send All Calls" call service feature.voidsetServerAddress(java.lang.String serverAddress)An optional parameter to specify the presence server address.
-
-
-
Method Detail
-
isEnabled
public boolean isEnabled()
Indicates whether the presence service is enabled.- Returns:
- true if the presence service is enabled, false otherwise.
-
setEnabled
public void setEnabled(boolean enabled)
Enables or disables the presence service.- Parameters:
enabled- true if presence support should be enabled, false otherwise.
-
getServerAddress
public java.lang.String getServerAddress()
Configured presence server address.- Returns:
- presence server address.
- See Also:
setServerAddress(String)
-
setServerAddress
public void setServerAddress(java.lang.String serverAddress)
An optional parameter to specify the presence server address.If configured, this server will be used as the domain in the request URI for all presence-related messages. Otherwise the address will be discovered automatically.
- Parameters:
serverAddress- The presence server address to use.
-
isSendAllCallsOnDoNotDisturb
public boolean isSendAllCallsOnDoNotDisturb()
Indicates a link between "Do Not Disturb" presence state and "Send All Calls" call service feature.- Returns:
- true if the link between "Do Not Disturb" presence state and "Send All Calls" call service feature is enabled, false otherwise.
- See Also:
setSendAllCallsOnDoNotDisturb(boolean)
-
setSendAllCallsOnDoNotDisturb
public void setSendAllCallsOnDoNotDisturb(boolean sendAllCallsOnDoNotDisturb)
Sets a link between "Do Not Disturb" presence state and "Send All Calls" call service feature.If the link is enabled and "Send All Calls" feature is available, the following behavior applies. Once the presence state of the user changes to "Do not Disturb", "Send All Calls" is automatically switched on. If the presence state of the user changes from "Do not Disturb" to any other state, "Send All Calls" is automatically switched off.
- Parameters:
sendAllCallsOnDoNotDisturb- boolean value to enable or disable a link between "Do Not Disturb" presence state and "Send All Calls" call service feature.
-
isPresenceUpdateInBackgroundEnabled
public boolean isPresenceUpdateInBackgroundEnabled()
Indicates whether contact presence updates should be monitored and reported even when mobile platform application is not visible.- Returns:
- true if the presence updates in background are enabled, false otherwise.
- See Also:
setPresenceUpdateInBackgroundEnabled(boolean)
-
setPresenceUpdateInBackgroundEnabled
public void setPresenceUpdateInBackgroundEnabled(boolean presenceUpdateInBackgroundEnabled)
Enables or disables contact presence monitoring when mobile platform application is not visible.Note: It is not recommended to enable this option since in most cases contact presence updates are not visible due to the application is running in background and active presence subscriptions result in useless network traffic and battery drain. This option might be useful for a specific setup where contact presence indicators are still visible even when the application is minimized.
Note: Presence updates are disabled in background by default.
- Parameters:
presenceUpdateInBackgroundEnabled- boolean true if presence update subscriptions should remain active in background, false otherwise.
-
setAwayTimeout
public void setAwayTimeout(long awayTimeout)
Sets the timeout for the user inactivity timer.Inactivity timer is used to automatically change the user's presence state to 'away' if the user is inactive, i.e. not using the device with the installed application. When the timer fires, the user's presence is set to the 'away' state. If zero value is specified, the inactivity timer is disabled.
- Parameters:
awayTimeout- Timeout in milliseconds.
-
getAwayTimeout
public long getAwayTimeout()
The user inactivity timeout period in milliseconds.- Returns:
- Away timeout in milliseconds.
-
-