ConnectionRequestpublic final class ConnectionRequest extends Object implements android.os.ParcelableSimple data container encapsulating a request to some entity to
create a new {@link Connection}. |
Fields Summary |
---|
private final PhoneAccountHandle | mAccountHandle | private final android.net.Uri | mAddress | private final android.os.Bundle | mExtras | private final int | mVideoState | public static final Creator | CREATOR |
Constructors Summary |
---|
public ConnectionRequest(PhoneAccountHandle accountHandle, android.net.Uri handle, android.os.Bundle extras)
this(accountHandle, handle, extras, VideoProfile.VideoState.AUDIO_ONLY);
| public ConnectionRequest(PhoneAccountHandle accountHandle, android.net.Uri handle, android.os.Bundle extras, int videoState)
mAccountHandle = accountHandle;
mAddress = handle;
mExtras = extras;
mVideoState = videoState;
| private ConnectionRequest(android.os.Parcel in)
mAccountHandle = in.readParcelable(getClass().getClassLoader());
mAddress = in.readParcelable(getClass().getClassLoader());
mExtras = in.readParcelable(getClass().getClassLoader());
mVideoState = in.readInt();
|
Methods Summary |
---|
public int | describeContents(){@inheritDoc}
return 0;
| public PhoneAccountHandle | getAccountHandle()The account which should be used to place the call. return mAccountHandle;
| public android.net.Uri | getAddress()The handle (e.g., phone number) to which the {@link Connection} is to connect. return mAddress;
| public android.os.Bundle | getExtras()Application-specific extra data. Used for passing back information from an incoming
call {@code Intent}, and for any proprietary extensions arranged between a client
and servant {@code ConnectionService} which agree on a vocabulary for such data. return mExtras;
| public int | getVideoState()Describes the video states supported by the client requesting the connection.
Valid values: {@link VideoProfile.VideoState#AUDIO_ONLY},
{@link VideoProfile.VideoState#BIDIRECTIONAL},
{@link VideoProfile.VideoState#TX_ENABLED},
{@link VideoProfile.VideoState#RX_ENABLED}.
return mVideoState;
| public java.lang.String | toString()
return String.format("ConnectionRequest %s %s",
mAddress == null
? Uri.EMPTY
: Connection.toLogSafePhoneNumber(mAddress.toString()),
mExtras == null ? "" : mExtras);
| public void | writeToParcel(android.os.Parcel destination, int flags)
destination.writeParcelable(mAccountHandle, 0);
destination.writeParcelable(mAddress, 0);
destination.writeParcelable(mExtras, 0);
destination.writeInt(mVideoState);
|
|