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

Commit ebb8cbc0 authored by Henri Chataing's avatar Henri Chataing
Browse files

Flags 24Q3: a2dp_offload_codec_extensibility

Bug: 308686081
Bug: 305734815
Test: m com.android.btservices
Flag: com.android.bluetooth.flags.a2dp_offload_codec_extensibility
Change-Id: Ib6ec846be96aed1a8bd7c31b5d04691a8e9d75da
parent 28b9115a
Loading
Loading
Loading
Loading
+0 −8
Original line number Diff line number Diff line
package: "com.android.bluetooth.flags"
container: "com.android.btservices"

flag {
    name: "a2dp_offload_codec_extensibility"
    is_exported: true
    namespace: "bluetooth"
    description: "Enable a2dp offload codec extensibility"
    bug: "308686081"
}

flag {
    name: "a2dp_service_looper"
    namespace: "bluetooth"
+10 −10
Original line number Diff line number Diff line
@@ -6,7 +6,7 @@ package android.bluetooth {
    method @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public java.util.List<android.bluetooth.BluetoothDevice> getConnectedDevices();
    method @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public int getConnectionState(android.bluetooth.BluetoothDevice);
    method @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public java.util.List<android.bluetooth.BluetoothDevice> getDevicesMatchingConnectionStates(int[]);
    method @FlaggedApi("com.android.bluetooth.flags.a2dp_offload_codec_extensibility") @NonNull @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public java.util.Collection<android.bluetooth.BluetoothCodecType> getSupportedCodecTypes();
    method @NonNull @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public java.util.Collection<android.bluetooth.BluetoothCodecType> getSupportedCodecTypes();
    method @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public boolean isA2dpPlaying(android.bluetooth.BluetoothDevice);
    field @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public static final String ACTION_CONNECTION_STATE_CHANGED = "android.bluetooth.a2dp.profile.action.CONNECTION_STATE_CHANGED";
    field @RequiresPermission(android.Manifest.permission.BLUETOOTH_CONNECT) public static final String ACTION_PLAYING_STATE_CHANGED = "android.bluetooth.a2dp.profile.action.PLAYING_STATE_CHANGED";
@@ -431,7 +431,7 @@ package android.bluetooth {
    method public long getCodecSpecific3();
    method public long getCodecSpecific4();
    method @Deprecated public int getCodecType();
    method @FlaggedApi("com.android.bluetooth.flags.a2dp_offload_codec_extensibility") @Nullable public android.bluetooth.BluetoothCodecType getExtendedCodecType();
    method @Nullable public android.bluetooth.BluetoothCodecType getExtendedCodecType();
    method public int getSampleRate();
    method public boolean isMandatoryCodec();
    method public void writeToParcel(android.os.Parcel, int);
@@ -474,7 +474,7 @@ package android.bluetooth {
    method @NonNull public android.bluetooth.BluetoothCodecConfig.Builder setCodecSpecific3(long);
    method @NonNull public android.bluetooth.BluetoothCodecConfig.Builder setCodecSpecific4(long);
    method @Deprecated @NonNull public android.bluetooth.BluetoothCodecConfig.Builder setCodecType(int);
    method @FlaggedApi("com.android.bluetooth.flags.a2dp_offload_codec_extensibility") @NonNull public android.bluetooth.BluetoothCodecConfig.Builder setExtendedCodecType(@Nullable android.bluetooth.BluetoothCodecType);
    method @NonNull public android.bluetooth.BluetoothCodecConfig.Builder setExtendedCodecType(@Nullable android.bluetooth.BluetoothCodecType);
    method @NonNull public android.bluetooth.BluetoothCodecConfig.Builder setSampleRate(int);
  }

@@ -497,19 +497,19 @@ package android.bluetooth {
    method @NonNull public android.bluetooth.BluetoothCodecStatus.Builder setCodecsSelectableCapabilities(@NonNull java.util.List<android.bluetooth.BluetoothCodecConfig>);
  }

  @FlaggedApi("com.android.bluetooth.flags.a2dp_offload_codec_extensibility") public final class BluetoothCodecType implements android.os.Parcelable {
    method @FlaggedApi("com.android.bluetooth.flags.a2dp_offload_codec_extensibility") public int describeContents();
    method @FlaggedApi("com.android.bluetooth.flags.a2dp_offload_codec_extensibility") public long getCodecId();
    method @FlaggedApi("com.android.bluetooth.flags.a2dp_offload_codec_extensibility") @NonNull public String getCodecName();
    method @FlaggedApi("com.android.bluetooth.flags.a2dp_offload_codec_extensibility") public boolean isMandatoryCodec();
    method @FlaggedApi("com.android.bluetooth.flags.a2dp_offload_codec_extensibility") public void writeToParcel(@NonNull android.os.Parcel, int);
  public final class BluetoothCodecType implements android.os.Parcelable {
    method public int describeContents();
    method public long getCodecId();
    method @NonNull public String getCodecName();
    method public boolean isMandatoryCodec();
    method public void writeToParcel(@NonNull android.os.Parcel, int);
    field public static final long CODEC_ID_AAC = 2L; // 0x2L
    field public static final long CODEC_ID_APTX = 16797695L; // 0x1004fffL
    field public static final long CODEC_ID_APTX_HD = 604035071L; // 0x2400d7ffL
    field public static final long CODEC_ID_LDAC = -1442763265L; // 0xffffffffaa012dffL
    field public static final long CODEC_ID_OPUS = 16834815L; // 0x100e0ffL
    field public static final long CODEC_ID_SBC = 0L; // 0x0L
    field @FlaggedApi("com.android.bluetooth.flags.a2dp_offload_codec_extensibility") @NonNull public static final android.os.Parcelable.Creator<android.bluetooth.BluetoothCodecType> CREATOR;
    field @NonNull public static final android.os.Parcelable.Creator<android.bluetooth.BluetoothCodecType> CREATOR;
  }

  public final class BluetoothCsipSetCoordinator implements java.lang.AutoCloseable android.bluetooth.BluetoothProfile {
+2 −2
Original line number Diff line number Diff line
@@ -161,9 +161,9 @@ package android.bluetooth {
    field public static final int PROFILE_PANU = 4; // 0x4
  }

  @FlaggedApi("com.android.bluetooth.flags.a2dp_offload_codec_extensibility") public final class BluetoothCodecType implements android.os.Parcelable {
  public final class BluetoothCodecType implements android.os.Parcelable {
    ctor public BluetoothCodecType(int, long, @NonNull String);
    method @FlaggedApi("com.android.bluetooth.flags.a2dp_offload_codec_extensibility") @Nullable public static android.bluetooth.BluetoothCodecType createFromType(int);
    method @Nullable public static android.bluetooth.BluetoothCodecType createFromType(int);
  }

  public final class BluetoothCsipSetCoordinator implements java.lang.AutoCloseable android.bluetooth.BluetoothProfile {
+0 −4
Original line number Diff line number Diff line
@@ -19,7 +19,6 @@ package android.bluetooth;
import static android.Manifest.permission.BLUETOOTH_CONNECT;
import static android.Manifest.permission.BLUETOOTH_PRIVILEGED;

import android.annotation.FlaggedApi;
import android.annotation.IntDef;
import android.annotation.NonNull;
import android.annotation.Nullable;
@@ -41,8 +40,6 @@ import android.os.ParcelUuid;
import android.os.RemoteException;
import android.util.Log;

import com.android.bluetooth.flags.Flags;

import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.util.Collection;
@@ -708,7 +705,6 @@ public final class BluetoothA2dp implements BluetoothProfile {
    @NonNull
    @RequiresLegacyBluetoothPermission
    @RequiresPermission(BLUETOOTH_PRIVILEGED)
    @FlaggedApi(Flags.FLAG_A2DP_OFFLOAD_CODEC_EXTENSIBILITY)
    public Collection<BluetoothCodecType> getSupportedCodecTypes() {
        Log.d(TAG, "getSupportedSourceCodecTypes()");
        final IBluetoothA2dp service = getService();
+0 −5
Original line number Diff line number Diff line
@@ -18,7 +18,6 @@ package android.bluetooth;

import static android.bluetooth.BluetoothUtils.formatSimple;

import android.annotation.FlaggedApi;
import android.annotation.IntDef;
import android.annotation.NonNull;
import android.annotation.Nullable;
@@ -27,8 +26,6 @@ import android.compat.annotation.UnsupportedAppUsage;
import android.os.Parcel;
import android.os.Parcelable;

import com.android.bluetooth.flags.Flags;

import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.util.Objects;
@@ -551,7 +548,6 @@ public final class BluetoothCodecConfig implements Parcelable {
    }

    /** Returns the source codec type of this config. */
    @FlaggedApi(Flags.FLAG_A2DP_OFFLOAD_CODEC_EXTENSIBILITY)
    public @Nullable BluetoothCodecType getExtendedCodecType() {
        return mCodecType;
    }
@@ -861,7 +857,6 @@ public final class BluetoothCodecConfig implements Parcelable {
         * @param codecType of this codec
         * @return the same Builder instance
         */
        @FlaggedApi(Flags.FLAG_A2DP_OFFLOAD_CODEC_EXTENSIBILITY)
        public @NonNull Builder setExtendedCodecType(@Nullable BluetoothCodecType codecType) {
            mCodecType = codecType;
            return this;
Loading