Fields Summary |
---|
private static final String | TAG |
public static final int | SERVICE_TYPE_NONEIt is for a special case. It helps that the application can make a call
without IMS connection (not registered).
In the moment of the call initiation, the device try to connect to the IMS network
and initiates the call. |
public static final int | SERVICE_TYPE_NORMALIt is a default type and can be selected when the device is connected to the IMS network. |
public static final int | SERVICE_TYPE_EMERGENCYIt is for an emergency call. |
public static final int | CALL_TYPE_VOICE_N_VIDEOIMSPhone to support IR.92 & IR.94 (voice + video upgrade/downgrade) |
public static final int | CALL_TYPE_VOICEIR.92 (Voice only) |
public static final int | CALL_TYPE_VIDEO_N_VOICEVT to support IR.92 & IR.94 (voice + video upgrade/downgrade) |
public static final int | CALL_TYPE_VTVideo Telephony (audio / video two way) |
public static final int | CALL_TYPE_VT_TXVideo Telephony (audio two way / video TX one way) |
public static final int | CALL_TYPE_VT_RXVideo Telephony (audio two way / video RX one way) |
public static final int | CALL_TYPE_VT_NODIRVideo Telephony (audio two way / video inactive) |
public static final int | CALL_TYPE_VSVideoShare (video two way) |
public static final int | CALL_TYPE_VS_TXVideoShare (video TX one way) |
public static final int | CALL_TYPE_VS_RXVideoShare (video RX one way) |
public static final String | EXTRA_CONFERENCEBoolean extra properties - "true" / "false"
conference : Indicates if the session is for the conference call or not.
e_call : Indicates if the session is for the emergency call or not.
vms : Indicates if the session is connected to the voice mail system or not.
call_mode_changeable : Indicates if the session is able to upgrade/downgrade
the video during voice call.
conference_avail : Indicates if the session can be extended to the conference. |
public static final String | EXTRA_E_CALL |
public static final String | EXTRA_VMS |
public static final String | EXTRA_CALL_MODE_CHANGEABLE |
public static final String | EXTRA_CONFERENCE_AVAIL |
public static final String | EXTRA_OEM_EXTRAS |
public static final String | EXTRA_OIRInteger extra properties
oir : Rule for originating identity (number) presentation, MO/MT.
{@link ImsCallProfile#OIR_DEFAULT}
{@link ImsCallProfile#OIR_PRESENTATION_RESTRICTED}
{@link ImsCallProfile#OIR_PRESENTATION_NOT_RESTRICTED}
cnap : Rule for calling name presentation
{@link ImsCallProfile#OIR_DEFAULT}
{@link ImsCallProfile#OIR_PRESENTATION_RESTRICTED}
{@link ImsCallProfile#OIR_PRESENTATION_NOT_RESTRICTED}
dialstring : To identify the Ims call type, MO
{@link ImsCallProfile#DIALSTRING_NORMAL_CALL}
{@link ImsCallProfile#DIALSTRING_SS_CONF}
{@link ImsCallProfile#DIALSTRING_USSD} |
public static final String | EXTRA_CNAP |
public static final String | EXTRA_DIALSTRING |
public static final int | OIR_DEFAULTValues for EXTRA_OIR / EXTRA_CNAP |
public static final int | OIR_PRESENTATION_RESTRICTED |
public static final int | OIR_PRESENTATION_NOT_RESTRICTED |
public static final int | DIALSTRING_NORMALValues for EXTRA_DIALSTRING |
public static final int | DIALSTRING_SS_CONF |
public static final int | DIALSTRING_USSD |
public static final int | CALL_RESTRICT_CAUSE_NONEValues for causes that restrict call types |
public static final int | CALL_RESTRICT_CAUSE_RAT |
public static final int | CALL_RESTRICT_CAUSE_DISABLED |
public static final int | CALL_RESTRICT_CAUSE_HD |
public static final String | EXTRA_OIString extra properties
oi : Originating identity (number), MT only
cna : Calling name
ussd : For network-initiated USSD, MT only
remote_uri : Connected user identity (it can be used for the conference) |
public static final String | EXTRA_CNA |
public static final String | EXTRA_USSD |
public static final String | EXTRA_REMOTE_URI |
public int | mServiceType |
public int | mCallType |
public int | mRestrictCause |
public android.os.Bundle | mCallExtras |
public ImsStreamMediaProfile | mMediaProfile |
public static final Creator | CREATOR |
Methods Summary |
---|
public static int | OIRToPresentation(int oir)Translate OIR value to presentation value
switch(oir) {
case ImsCallProfile.OIR_PRESENTATION_RESTRICTED:
return PhoneConstants.PRESENTATION_RESTRICTED;
case ImsCallProfile.OIR_PRESENTATION_NOT_RESTRICTED:
return PhoneConstants.PRESENTATION_ALLOWED;
default:
return PhoneConstants.PRESENTATION_UNKNOWN;
}
|
public int | describeContents()
return 0;
|
public java.lang.String | getCallExtra(java.lang.String name)
return getCallExtra(name, "");
|
public java.lang.String | getCallExtra(java.lang.String name, java.lang.String defaultValue)
if (mCallExtras == null) {
return defaultValue;
}
return mCallExtras.getString(name, defaultValue);
|
public boolean | getCallExtraBoolean(java.lang.String name)
return getCallExtraBoolean(name, false);
|
public boolean | getCallExtraBoolean(java.lang.String name, boolean defaultValue)
if (mCallExtras == null) {
return defaultValue;
}
return mCallExtras.getBoolean(name, defaultValue);
|
public int | getCallExtraInt(java.lang.String name)
return getCallExtraInt(name, -1);
|
public int | getCallExtraInt(java.lang.String name, int defaultValue)
if (mCallExtras == null) {
return defaultValue;
}
return mCallExtras.getInt(name, defaultValue);
|
public static int | getCallTypeFromVideoState(int videoState)Converts from the video state values defined in {@link VideoProfile}
to the call types defined in {@link ImsCallProfile}.
boolean videoTx = isVideoStateSet(videoState, VideoProfile.VideoState.TX_ENABLED);
boolean videoRx = isVideoStateSet(videoState, VideoProfile.VideoState.RX_ENABLED);
boolean isPaused = isVideoStateSet(videoState, VideoProfile.VideoState.PAUSED);
if (isPaused) {
return ImsCallProfile.CALL_TYPE_VT_NODIR;
} else if (videoTx && !videoRx) {
return ImsCallProfile.CALL_TYPE_VT_TX;
} else if (!videoTx && videoRx) {
return ImsCallProfile.CALL_TYPE_VT_RX;
} else if (videoTx && videoRx) {
return ImsCallProfile.CALL_TYPE_VT;
}
return ImsCallProfile.CALL_TYPE_VOICE;
|
public static int | getVideoStateFromCallType(int callType)Converts from the call types defined in {@link com.android.ims.ImsCallProfile} to the
video state values defined in {@link VideoProfile}.
switch (callType) {
case CALL_TYPE_VT_NODIR:
return VideoProfile.VideoState.PAUSED |
VideoProfile.VideoState.BIDIRECTIONAL;
case CALL_TYPE_VT_TX:
return VideoProfile.VideoState.TX_ENABLED;
case CALL_TYPE_VT_RX:
return VideoProfile.VideoState.RX_ENABLED;
case CALL_TYPE_VT:
return VideoProfile.VideoState.BIDIRECTIONAL;
case CALL_TYPE_VOICE:
return VideoProfile.VideoState.AUDIO_ONLY;
default:
return VideoProfile.VideoState.AUDIO_ONLY;
}
|
private static boolean | isVideoStateSet(int videoState, int videoStateToCheck)Determines if a video state is set in a video state bit-mask.
return (videoState & videoStateToCheck) == videoStateToCheck;
|
public static int | presentationToOIR(int presentation)Translate presentation value to OIR value
switch (presentation) {
case PhoneConstants.PRESENTATION_RESTRICTED:
return ImsCallProfile.OIR_PRESENTATION_RESTRICTED;
case PhoneConstants.PRESENTATION_ALLOWED:
return ImsCallProfile.OIR_PRESENTATION_NOT_RESTRICTED;
default:
return ImsCallProfile.OIR_DEFAULT;
}
|
private void | readFromParcel(android.os.Parcel in)
mServiceType = in.readInt();
mCallType = in.readInt();
mCallExtras = in.readParcelable(null);
mMediaProfile = in.readParcelable(null);
|
public void | setCallExtra(java.lang.String name, java.lang.String value)
if (mCallExtras != null) {
mCallExtras.putString(name, value);
}
|
public void | setCallExtraBoolean(java.lang.String name, boolean value)
if (mCallExtras != null) {
mCallExtras.putBoolean(name, value);
}
|
public void | setCallExtraInt(java.lang.String name, int value)
if (mCallExtras != null) {
mCallExtras.putInt(name, value);
}
|
public java.lang.String | toString()
return "{ serviceType=" + mServiceType +
", callType=" + mCallType +
", restrictCause=" + mRestrictCause +
", callExtras=" + mCallExtras.toString() +
", mediaProfile=" + mMediaProfile.toString() + " }";
|
public void | updateCallExtras(com.android.ims.ImsCallProfile profile)
mCallExtras.clear();
mCallExtras = (Bundle) profile.mCallExtras.clone();
|
public void | updateCallType(com.android.ims.ImsCallProfile profile)
mCallType = profile.mCallType;
|
public void | writeToParcel(android.os.Parcel out, int flags)
out.writeInt(mServiceType);
out.writeInt(mCallType);
out.writeParcelable(mCallExtras, 0);
out.writeParcelable(mMediaProfile, 0);
|