FileDocCategorySizeDatePackage
ParcelableCall.javaAPI DocAndroid 5.1 API11268Thu Mar 12 22:22:42 GMT 2015android.telecom

ParcelableCall

public final class ParcelableCall extends Object implements android.os.Parcelable
Information about a call that is used between InCallService and Telecom.
hide

Fields Summary
private final String
mId
private final int
mState
private final DisconnectCause
mDisconnectCause
private final List
mCannedSmsResponses
private final int
mCapabilities
private final int
mProperties
private final long
mConnectTimeMillis
private final android.net.Uri
mHandle
private final int
mHandlePresentation
private final String
mCallerDisplayName
private final int
mCallerDisplayNamePresentation
private final GatewayInfo
mGatewayInfo
private final PhoneAccountHandle
mAccountHandle
private final com.android.internal.telecom.IVideoProvider
mVideoCallProvider
private InCallService.VideoCall
mVideoCall
private final String
mParentCallId
private final List
mChildCallIds
private final StatusHints
mStatusHints
private final int
mVideoState
private final List
mConferenceableCallIds
private final android.os.Bundle
mExtras
public static final Parcelable.Creator
CREATOR
Responsible for creating ParcelableCall objects for deserialized Parcels.
Constructors Summary
public ParcelableCall(String id, int state, DisconnectCause disconnectCause, List cannedSmsResponses, int capabilities, int properties, long connectTimeMillis, android.net.Uri handle, int handlePresentation, String callerDisplayName, int callerDisplayNamePresentation, GatewayInfo gatewayInfo, PhoneAccountHandle accountHandle, com.android.internal.telecom.IVideoProvider videoCallProvider, String parentCallId, List childCallIds, StatusHints statusHints, int videoState, List conferenceableCallIds, android.os.Bundle extras)

        mId = id;
        mState = state;
        mDisconnectCause = disconnectCause;
        mCannedSmsResponses = cannedSmsResponses;
        mCapabilities = capabilities;
        mProperties = properties;
        mConnectTimeMillis = connectTimeMillis;
        mHandle = handle;
        mHandlePresentation = handlePresentation;
        mCallerDisplayName = callerDisplayName;
        mCallerDisplayNamePresentation = callerDisplayNamePresentation;
        mGatewayInfo = gatewayInfo;
        mAccountHandle = accountHandle;
        mVideoCallProvider = videoCallProvider;
        mParentCallId = parentCallId;
        mChildCallIds = childCallIds;
        mStatusHints = statusHints;
        mVideoState = videoState;
        mConferenceableCallIds = Collections.unmodifiableList(conferenceableCallIds);
        mExtras = extras;
    
Methods Summary
public intdescribeContents()
{@inheritDoc}


      
    
       
        return 0;
    
public PhoneAccountHandlegetAccountHandle()
PhoneAccountHandle information for the call.

        return mAccountHandle;
    
public java.lang.StringgetCallerDisplayName()
The endpoint to which the call is connected.

        return mCallerDisplayName;
    
public intgetCallerDisplayNamePresentation()
The presentation requirements for the caller display name. See {@link TelecomManager} for valid values.

        return mCallerDisplayNamePresentation;
    
public java.util.ListgetCannedSmsResponses()
The set of possible text message responses when this call is incoming.

        return mCannedSmsResponses;
    
public intgetCapabilities()

        return mCapabilities;
    
public java.util.ListgetChildCallIds()
The child call-IDs if this call is a conference call. Returns an empty list if this is not a conference call or if the conference call contains no children.

        return mChildCallIds;
    
public java.util.ListgetConferenceableCallIds()

        return mConferenceableCallIds;
    
public longgetConnectTimeMillis()
The time that the call switched to the active state.

        return mConnectTimeMillis;
    
public DisconnectCausegetDisconnectCause()
Reason for disconnection, as described by {@link android.telecomm.DisconnectCause}. Valid when call state is {@link CallState#DISCONNECTED}.

        return mDisconnectCause;
    
public android.os.BundlegetExtras()
Any extras to pass with the call

return
a bundle of extras

        return mExtras;
    
public GatewayInfogetGatewayInfo()
Gateway information for the call.

        return mGatewayInfo;
    
public android.net.UrigetHandle()
The endpoint to which the call is connected.

        return mHandle;
    
public intgetHandlePresentation()
The presentation requirements for the handle. See {@link TelecomManager} for valid values.

        return mHandlePresentation;
    
public java.lang.StringgetId()
The unique ID of the call.

        return mId;
    
public java.lang.StringgetParentCallId()
The conference call to which this call is conferenced. Null if not conferenced.

        return mParentCallId;
    
public intgetProperties()
Bitmask of properties of the call.

 return mProperties; 
public intgetState()
The current state of the call.

        return mState;
    
public StatusHintsgetStatusHints()
The status label and icon.

return
Status hints.

        return mStatusHints;
    
public InCallService.VideoCallgetVideoCall()
Returns an object for remotely communicating through the video call provider's binder.

return
The video call.

        if (mVideoCall == null && mVideoCallProvider != null) {
            try {
                mVideoCall = new VideoCallImpl(mVideoCallProvider);
            } catch (RemoteException ignored) {
                // Ignore RemoteException.
            }
        }

        return mVideoCall;
    
public intgetVideoState()
The video state.

return
The video state of the call.

        return mVideoState;
    
public java.lang.StringtoString()

        return String.format("[%s, parent:%s, children:%s]", mId, mParentCallId, mChildCallIds);
    
public voidwriteToParcel(android.os.Parcel destination, int flags)
Writes ParcelableCall object into a Parcel.

        destination.writeString(mId);
        destination.writeInt(mState);
        destination.writeParcelable(mDisconnectCause, 0);
        destination.writeList(mCannedSmsResponses);
        destination.writeInt(mCapabilities);
        destination.writeInt(mProperties);
        destination.writeLong(mConnectTimeMillis);
        destination.writeParcelable(mHandle, 0);
        destination.writeInt(mHandlePresentation);
        destination.writeString(mCallerDisplayName);
        destination.writeInt(mCallerDisplayNamePresentation);
        destination.writeParcelable(mGatewayInfo, 0);
        destination.writeParcelable(mAccountHandle, 0);
        destination.writeStrongBinder(
                mVideoCallProvider != null ? mVideoCallProvider.asBinder() : null);
        destination.writeString(mParentCallId);
        destination.writeList(mChildCallIds);
        destination.writeParcelable(mStatusHints, 0);
        destination.writeInt(mVideoState);
        destination.writeList(mConferenceableCallIds);
        destination.writeParcelable(mExtras, 0);