Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e9544264 authored by Evan Charlton's avatar Evan Charlton Committed by Android (Google) Code Review
Browse files

Merge "Rename PhoneAccountMetadata to PhoneAccount" into lmp-dev

parents 89435ce6 8c8a062f
Loading
Loading
Loading
Loading
+17 −17
Original line number Diff line number Diff line
@@ -28312,7 +28312,7 @@ package android.telecomm {
  }
  public static class Call.Details {
    method public android.telecomm.PhoneAccountHandle getAccount();
    method public android.telecomm.PhoneAccountHandle getAccountHandle();
    method public java.lang.String getCallerDisplayName();
    method public int getCallerDisplayNamePresentation();
    method public int getCapabilities();
@@ -28498,7 +28498,7 @@ package android.telecomm {
  public final class ConnectionRequest implements android.os.Parcelable {
    ctor public ConnectionRequest(android.telecomm.PhoneAccountHandle, java.lang.String, android.net.Uri, int, android.os.Bundle, int);
    method public int describeContents();
    method public android.telecomm.PhoneAccountHandle getAccount();
    method public android.telecomm.PhoneAccountHandle getAccountHandle();
    method public java.lang.String getCallId();
    method public android.os.Bundle getExtras();
    method public android.net.Uri getHandle();
@@ -28557,7 +28557,7 @@ package android.telecomm {
  public final class InCallCall implements android.os.Parcelable {
    method public int describeContents();
    method public android.telecomm.PhoneAccountHandle getAccount();
    method public android.telecomm.PhoneAccountHandle getAccountHandle();
    method public android.telecomm.RemoteCallVideoProvider getCallVideoProvider() throws android.os.RemoteException;
    method public java.lang.String getCallerDisplayName();
    method public int getCallerDisplayNamePresentation();
@@ -28602,19 +28602,10 @@ package android.telecomm {
    method public void onCallRemoved(android.telecomm.Phone, android.telecomm.Call);
  }
  public class PhoneAccountHandle implements android.os.Parcelable {
    ctor public PhoneAccountHandle(android.content.ComponentName, java.lang.String);
    method public int describeContents();
    method public android.content.ComponentName getComponentName();
    method public java.lang.String getId();
    method public void writeToParcel(android.os.Parcel, int);
    field public static final android.os.Parcelable.Creator CREATOR;
  }
  public class PhoneAccountMetadata implements android.os.Parcelable {
    ctor public PhoneAccountMetadata(android.telecomm.PhoneAccountHandle, android.net.Uri, java.lang.String, int, int, java.lang.String, java.lang.String, boolean);
  public class PhoneAccount implements android.os.Parcelable {
    ctor public PhoneAccount(android.telecomm.PhoneAccountHandle, android.net.Uri, java.lang.String, int, int, java.lang.String, java.lang.String, boolean);
    method public int describeContents();
    method public android.telecomm.PhoneAccountHandle getAccount();
    method public android.telecomm.PhoneAccountHandle getAccountHandle();
    method public int getCapabilities();
    method public android.net.Uri getHandle();
    method public android.graphics.drawable.Drawable getIcon(android.content.Context);
@@ -28630,6 +28621,15 @@ package android.telecomm {
    field public static final android.os.Parcelable.Creator CREATOR;
  }
  public class PhoneAccountHandle implements android.os.Parcelable {
    ctor public PhoneAccountHandle(android.content.ComponentName, java.lang.String);
    method public int describeContents();
    method public android.content.ComponentName getComponentName();
    method public java.lang.String getId();
    method public void writeToParcel(android.os.Parcel, int);
    field public static final android.os.Parcelable.Creator CREATOR;
  }
  public class RemoteCallVideoClient implements android.os.IBinder.DeathRecipient {
    method public void binderDied();
    method public void handleCallSessionEvent(int) throws android.os.RemoteException;
@@ -28722,8 +28722,8 @@ package android.telecomm {
    method public void clearAccounts(java.lang.String);
    method public android.telecomm.PhoneAccountHandle getDefaultOutgoingPhoneAccount();
    method public java.util.List<android.telecomm.PhoneAccountHandle> getEnabledPhoneAccounts();
    method public android.telecomm.PhoneAccountMetadata getPhoneAccountMetadata(android.telecomm.PhoneAccountHandle);
    method public void registerPhoneAccount(android.telecomm.PhoneAccountMetadata);
    method public android.telecomm.PhoneAccount getPhoneAccount(android.telecomm.PhoneAccountHandle);
    method public void registerPhoneAccount(android.telecomm.PhoneAccount);
    method public void unregisterPhoneAccount(android.telecomm.PhoneAccountHandle);
    field public static final java.lang.String ACTION_CONNECTION_SERVICE;
    field public static final java.lang.String ACTION_CONNECTION_SERVICE_CONFIGURE = "android.intent.action.CONNECTION_SERVICE_CONFIGURE";
+6 −6
Original line number Diff line number Diff line
@@ -343,7 +343,7 @@ public class CallLog {
         *        "allowed", "payphone", "restricted" or "unknown"
         * @param callType enumerated values for "incoming", "outgoing", or "missed"
         * @param features features of the call (e.g. Video).
         * @param account The account object describing the provider of the call
         * @param accountHandle The accountHandle object identifying the provider of the call
         * @param start time stamp for the call in milliseconds
         * @param duration call duration in seconds
         * @param dataUsage data usage for the call in bytes, null if data usage was not tracked for
@@ -352,7 +352,7 @@ public class CallLog {
         * {@hide}
         */
        public static Uri addCall(CallerInfo ci, Context context, String number,
                int presentation, int callType, int features, PhoneAccountHandle account,
                int presentation, int callType, int features, PhoneAccountHandle accountHandle,
                long start, int duration, Long dataUsage) {
            final ContentResolver resolver = context.getContentResolver();
            int numberPresentation = PRESENTATION_ALLOWED;
@@ -377,12 +377,12 @@ public class CallLog {
                }
            }

            // account information
            // accountHandle information
            String accountComponentString = null;
            String accountId = null;
            if (account != null) {
                accountComponentString = account.getComponentName().flattenToString();
                accountId = account.getId();
            if (accountHandle != null) {
                accountComponentString = accountHandle.getComponentName().flattenToString();
                accountId = accountHandle.getId();
            }

            ContentValues values = new ContentValues(6);
+12 −12
Original line number Diff line number Diff line
@@ -73,7 +73,7 @@ public final class Call {
        private final int mHandlePresentation;
        private final String mCallerDisplayName;
        private final int mCallerDisplayNamePresentation;
        private final PhoneAccountHandle mAccount;
        private final PhoneAccountHandle mAccountHandle;
        private final int mCapabilities;
        private final int mDisconnectCauseCode;
        private final String mDisconnectCauseMsg;
@@ -117,8 +117,8 @@ public final class Call {
         * @return The {@code PhoneAccountHandle} whereby the {@code Call} is currently being
         * routed.
         */
        public PhoneAccountHandle getAccount() {
            return mAccount;
        public PhoneAccountHandle getAccountHandle() {
            return mAccountHandle;
        }

        /**
@@ -185,7 +185,7 @@ public final class Call {
                        Objects.equals(mCallerDisplayName, d.mCallerDisplayName) &&
                        Objects.equals(mCallerDisplayNamePresentation,
                                d.mCallerDisplayNamePresentation) &&
                        Objects.equals(mAccount, d.mAccount) &&
                        Objects.equals(mAccountHandle, d.mAccountHandle) &&
                        Objects.equals(mCapabilities, d.mCapabilities) &&
                        Objects.equals(mDisconnectCauseCode, d.mDisconnectCauseCode) &&
                        Objects.equals(mDisconnectCauseMsg, d.mDisconnectCauseMsg) &&
@@ -204,7 +204,7 @@ public final class Call {
                    Objects.hashCode(mHandlePresentation) +
                    Objects.hashCode(mCallerDisplayName) +
                    Objects.hashCode(mCallerDisplayNamePresentation) +
                    Objects.hashCode(mAccount) +
                    Objects.hashCode(mAccountHandle) +
                    Objects.hashCode(mCapabilities) +
                    Objects.hashCode(mDisconnectCauseCode) +
                    Objects.hashCode(mDisconnectCauseMsg) +
@@ -220,7 +220,7 @@ public final class Call {
                int handlePresentation,
                String callerDisplayName,
                int callerDisplayNamePresentation,
                PhoneAccountHandle account,
                PhoneAccountHandle accountHandle,
                int capabilities,
                int disconnectCauseCode,
                String disconnectCauseMsg,
@@ -232,7 +232,7 @@ public final class Call {
            mHandlePresentation = handlePresentation;
            mCallerDisplayName = callerDisplayName;
            mCallerDisplayNamePresentation = callerDisplayNamePresentation;
            mAccount = account;
            mAccountHandle = accountHandle;
            mCapabilities = capabilities;
            mDisconnectCauseCode = disconnectCauseCode;
            mDisconnectCauseMsg = disconnectCauseMsg;
@@ -458,11 +458,11 @@ public final class Call {
    }

    /**
     * Notifies this {@code Call} the a {@code PhoneAccountHandle} has been selected and to proceed
     * with placing an outgoing call.
     * Notifies this {@code Call} that an account has been selected and to proceed with placing
     * an outgoing call.
     */
    public void phoneAccountSelected(PhoneAccountHandle account) {
        mInCallAdapter.phoneAccountSelected(mTelecommCallId, account);
    public void phoneAccountSelected(PhoneAccountHandle accountHandle) {
        mInCallAdapter.phoneAccountSelected(mTelecommCallId, accountHandle);

    }

@@ -589,7 +589,7 @@ public final class Call {
                inCallCall.getHandlePresentation(),
                inCallCall.getCallerDisplayName(),
                inCallCall.getCallerDisplayNamePresentation(),
                inCallCall.getAccount(),
                inCallCall.getAccountHandle(),
                inCallCall.getCapabilities(),
                inCallCall.getDisconnectCauseCode(),
                inCallCall.getDisconnectCauseMsg(),
+3 −3
Original line number Diff line number Diff line
@@ -33,9 +33,9 @@ public enum CallState {

    /**
     * Indicates that the call is about to go into the outgoing and dialing state but is waiting for
     * user input before it proceeds. For example, where no default {@link PhoneAccountHandle} is
     * set, this is the state where the InCallUI is waiting for the user to select a
     * {@link PhoneAccountHandle} to call from.
     * user input before it proceeds. For example, where no default {@link PhoneAccount} is set,
     * this is the state where the InCallUI is waiting for the user to select a
     * {@link PhoneAccount} to call from.
     */
    PRE_DIAL_WAIT,

+7 −7
Original line number Diff line number Diff line
@@ -30,7 +30,7 @@ public final class ConnectionRequest implements Parcelable {
    // TODO: Token to limit recursive invocations
    // TODO: Consider upgrading "mHandle" to ordered list of handles, indicating a set of phone
    //         numbers that would satisfy the client's needs, in order of preference
    private final PhoneAccountHandle mAccount;
    private final PhoneAccountHandle mAccountHandle;
    private final String mCallId;
    private final Uri mHandle;
    private final int mHandlePresentation;
@@ -38,7 +38,7 @@ public final class ConnectionRequest implements Parcelable {
    private final int mVideoState;

    /**
     * @param account The account which should be used to place the call.
     * @param accountHandle The accountHandle which should be used to place the call.
     * @param callId An identifier for this call.
     * @param handle The handle (e.g., phone number) to which the {@link Connection} is to connect.
     * @param handlePresentation The {@link CallPropertyPresentation} which controls how the handle
@@ -47,13 +47,13 @@ public final class ConnectionRequest implements Parcelable {
     * @param videoState Determines the video state for the connection.
     */
    public ConnectionRequest(
            PhoneAccountHandle account,
            PhoneAccountHandle accountHandle,
            String callId,
            Uri handle,
            int handlePresentation,
            Bundle extras,
            int videoState) {
        mAccount = account;
        mAccountHandle = accountHandle;
        mCallId = callId;
        mHandle = handle;
        mHandlePresentation = handlePresentation;
@@ -62,7 +62,7 @@ public final class ConnectionRequest implements Parcelable {
    }

    private ConnectionRequest(Parcel in) {
        mAccount = in.readParcelable(getClass().getClassLoader());
        mAccountHandle = in.readParcelable(getClass().getClassLoader());
        mCallId = in.readString();
        mHandle = in.readParcelable(getClass().getClassLoader());
        mHandlePresentation = in.readInt();
@@ -73,7 +73,7 @@ public final class ConnectionRequest implements Parcelable {
    /**
     * The account which should be used to place the call.
     */
    public PhoneAccountHandle getAccount() { return mAccount; }
    public PhoneAccountHandle getAccountHandle() { return mAccountHandle; }

    /**
     * An identifier for this call.
@@ -140,7 +140,7 @@ public final class ConnectionRequest implements Parcelable {

    @Override
    public void writeToParcel(Parcel destination, int flags) {
        destination.writeParcelable(mAccount, 0);
        destination.writeParcelable(mAccountHandle, 0);
        destination.writeString(mCallId);
        destination.writeParcelable(mHandle, 0);
        destination.writeInt(mHandlePresentation);
Loading