CallAttributesCompat
public final class CallAttributesCompat
CallAttributes represents a set of properties that define a new Call. Applications should build an instance of this class and use CallsManager.addCall to start a new call with Telecom.
Summary
Constants |
|
|---|---|
static final int |
Used when answering or dialing a call to indicate that the call does not have a video component |
static final int |
Indicates video transmission is supported |
static final int |
Indicates that the call is an incoming call. |
static final int |
Indicates that the call is an outgoing call. |
static final int |
This call being created can be set to inactive (traditionally referred to as hold). |
static final int |
This call can be streamed from a root device to another device to continue the call without completely transferring it. |
static final int |
This call can be completely transferred from one endpoint to another. |
Public constructors |
|---|
CallAttributesCompat( |
Public methods |
|
|---|---|
boolean |
|
final @NonNull Uri |
Address of the call. |
final int |
Allows a package to opt into capabilities on the telecom side, on a per-call basis |
final int |
Information related to data being transmitted (voice, video, etc. ) |
final int |
The direction (Outgoing/Incoming) of the new Call |
final @NonNull CharSequence |
Display name of the person on the other end of the call |
final CallEndpointCompat |
allows clients to specify a |
int |
hashCode() |
final Boolean |
Whether this call should be excluded from the call log. |
@NonNull String |
toString() |
Constants
CALL_TYPE_AUDIO_CALL
public static final int CALL_TYPE_AUDIO_CALL = 1
Used when answering or dialing a call to indicate that the call does not have a video component
CALL_TYPE_VIDEO_CALL
public static final int CALL_TYPE_VIDEO_CALL = 2
Indicates video transmission is supported
DIRECTION_INCOMING
public static final int DIRECTION_INCOMING = 1
Indicates that the call is an incoming call.
DIRECTION_OUTGOING
public static final int DIRECTION_OUTGOING = 2
Indicates that the call is an outgoing call.
SUPPORTS_SET_INACTIVE
public static final int SUPPORTS_SET_INACTIVE
This call being created can be set to inactive (traditionally referred to as hold). This means that once a new call goes active, if the active call needs to be held in order to place or receive an incoming call, the active call will be placed on hold. otherwise, the active call may be disconnected.
SUPPORTS_STREAM
public static final int SUPPORTS_STREAM
This call can be streamed from a root device to another device to continue the call without completely transferring it. The call continues to take place on the source device, however media and control are streamed to another device.
SUPPORTS_TRANSFER
public static final int SUPPORTS_TRANSFER
This call can be completely transferred from one endpoint to another.
Public constructors
CallAttributesCompat
public CallAttributesCompat(
@NonNull CharSequence displayName,
@NonNull Uri address,
int direction,
int callType,
int callCapabilities,
CallEndpointCompat preferredStartingCallEndpoint,
Boolean isLogExcluded
)
| Parameters | |
|---|---|
@NonNull CharSequence displayName |
Display name of the person on the other end of the call |
@NonNull Uri address |
Address of the call. Note, this can be extended to a meeting link or a custom scheme. On sdks 26 & 27, the address should start with the "sip:" prefix (e.g Uri.parse("sip:")), otherwise the address will be replaced with "sip:" + packageName. |
int direction |
The direction (Outgoing/Incoming) of the new Call |
int callType |
Information related to data being transmitted (voice, video, etc. ) |
int callCapabilities |
Allows a package to opt into capabilities on the telecom side, on a per-call basis |
CallEndpointCompat preferredStartingCallEndpoint |
allows clients to specify a |
Boolean isLogExcluded |
Whether this call should be excluded from the call log. This is only applicable on sdks 36.1+. Pass null if the default platform behavior is desired or when running on older versions. |
Public methods
getAddress
public final @NonNull Uri getAddress()
Address of the call. Note, this can be extended to a meeting link or a custom scheme. On sdks 26 & 27, the address should start with the "sip:" prefix (e.g Uri.parse("sip:")), otherwise the address will be replaced with "sip:" + packageName.
getCallCapabilities
public final int getCallCapabilities()
Allows a package to opt into capabilities on the telecom side, on a per-call basis
getCallType
public final int getCallType()
Information related to data being transmitted (voice, video, etc. )
getDirection
public final int getDirection()
The direction (Outgoing/Incoming) of the new Call
getDisplayName
public final @NonNull CharSequence getDisplayName()
Display name of the person on the other end of the call
getPreferredStartingCallEndpoint
public final CallEndpointCompat getPreferredStartingCallEndpoint()
allows clients to specify a CallEndpointCompat to start a new call on. The preferredStartingCallEndpoint should be a value returned from CallsManager.getAvailableStartingCallEndpoints. Once the call is started, Core-Telecom will switch to the preferredStartingCallEndpoint before running the CallControlScope.
isLogExcluded
public final Boolean isLogExcluded()
Whether this call should be excluded from the call log. This is only applicable on sdks 36.1+. Pass null if the default platform behavior is desired or when running on older versions.