public class

RcsServiceControl

extends Object
java.lang.Object
   ↳ com.gsma.services.rcs.RcsServiceControl

Class Overview

A utility class to control the activation of the RCS service.

Summary

Constants
String RCS_STACK_PACKAGENAME RCS stack package name
Public Methods
static RcsServiceControl getInstance(Context ctx)
Gets an instance of RcsServiceControl
boolean isActivated()
Returns true if the RCS stack is marked as active on the device.
boolean isActivationModeChangeable()
Returns true if the RCS stack de-activation/activation is allowed by the client.
boolean isAvailable()
Returns true if the RCS stack is installed and not disabled on the device.
boolean isServiceStarted()
Returns true if the RCS stack is started.
void setActivationMode(boolean active)
Deactive/Activate the RCS stack in case these operations are allowed (see isStackActivationStatusChangeable) or else throws an RcsPermissionDeniedException.
[Expand]
Inherited Methods
From class java.lang.Object

Constants

public static final String RCS_STACK_PACKAGENAME

Since: API Level 1.5

RCS stack package name

Constant Value: "com.gsma.rcs"

Public Methods

public static RcsServiceControl getInstance (Context ctx)

Since: API Level 1.5

Gets an instance of RcsServiceControl

Parameters
ctx the context.
Returns
  • RcsServiceControl the singleton instance.

public boolean isActivated ()

Since: API Level 1.5

Returns true if the RCS stack is marked as active on the device.

Returns
  • boolean true if the RCS stack is marked as active on the device.

public boolean isActivationModeChangeable ()

Since: API Level 1.5

Returns true if the RCS stack de-activation/activation is allowed by the client.

Returns
  • boolean true if the RCS stack de-activation/activation is allowed by the client.

public boolean isAvailable ()

Since: API Level 1.5

Returns true if the RCS stack is installed and not disabled on the device.

Returns
  • boolean true if the RCS stack is installed and not disabled on the device.

public boolean isServiceStarted ()

Since: API Level 1.5

Returns true if the RCS stack is started.

Returns
  • boolean true if the RCS stack is started.

public void setActivationMode (boolean active)

Since: API Level 1.5

Deactive/Activate the RCS stack in case these operations are allowed (see isStackActivationStatusChangeable) or else throws an RcsPermissionDeniedException.

Parameters
active True is activation is enabled.
Throws
RcsPermissionDeniedException
RcsGenericException
RcsPermissionDeniedException