Loading core/api/system-current.txt +1 −1 Original line number Diff line number Diff line Loading @@ -3348,7 +3348,7 @@ package android.app.wearable { field public static final int STATUS_SERVICE_UNAVAILABLE = 3; // 0x3 field public static final int STATUS_SUCCESS = 1; // 0x1 field public static final int STATUS_UNKNOWN = 0; // 0x0 field public static final int STATUS_UNSUPPORTED = 2; // 0x2 field @Deprecated public static final int STATUS_UNSUPPORTED = 2; // 0x2 field @FlaggedApi("android.app.wearable.enable_data_request_observer_api") public static final int STATUS_UNSUPPORTED_DATA_TYPE = 8; // 0x8 field @FlaggedApi("android.app.wearable.enable_unsupported_operation_status_code") public static final int STATUS_UNSUPPORTED_OPERATION = 6; // 0x6 field public static final int STATUS_WEARABLE_UNAVAILABLE = 4; // 0x4 core/java/android/app/wearable/WearableSensingManager.java +5 −5 Original line number Diff line number Diff line Loading @@ -95,11 +95,12 @@ public class WearableSensingManager { /** * The value of the status code that indicates one or more of the requested events are not * supported. * * @deprecated WearableSensingManager does not deal with events. Use {@link * STATUS_UNSUPPORTED_OPERATION} instead for operations not supported by the implementation of * {@link WearableSensingService}. */ // TODO(b/324635656): Deprecate this status code. Update Javadoc: // @deprecated WearableSensingManager does not deal with events. Use {@link // STATUS_UNSUPPORTED_OPERATION} instead for operations not supported by the implementation of // {@link WearableSensingService}. @Deprecated public static final int STATUS_UNSUPPORTED = 2; /** Loading @@ -121,7 +122,6 @@ public class WearableSensingManager { * The value of the status code that indicates the method called is not supported by the * implementation of {@link WearableSensingService}. */ @FlaggedApi(Flags.FLAG_ENABLE_UNSUPPORTED_OPERATION_STATUS_CODE) public static final int STATUS_UNSUPPORTED_OPERATION = 6; Loading core/java/android/service/voice/AlwaysOnHotwordDetector.java +5 −9 Original line number Diff line number Diff line Loading @@ -819,19 +819,15 @@ public class AlwaysOnHotwordDetector extends AbstractDetector { /** * Called when the keyphrase is spoken. * * <p>This implicitly stops listening for the keyphrase once it's detected. Clients should * start a recognition again once they are done handling this detection. * <p>If {@code eventPayload.isRecognitionStopped()} returns true, this implicitly stops * listening for the keyphrase once it's detected. Clients should start a recognition again * once they are done handling this detection. * * @param eventPayload Payload data for the detection event. This may contain the trigger * audio, if requested when calling {@link * AlwaysOnHotwordDetector#startRecognition(int)}. */ // TODO(b/324635656): Update Javadoc for 24Q3 release: // 1. Prepend to the first paragraph: // If {@code eventPayload.isRecognitionStopped()} returns true, this... // 2. Append to the description for @param eventPayload: // ...or if the audio comes from {@link // android.service.wearable.WearableSensingService}. * AlwaysOnHotwordDetector#startRecognition(int)} or if the audio comes from the {@link * android.service.wearable.WearableSensingService}. */ public abstract void onDetected(@NonNull EventPayload eventPayload); /** Loading core/java/android/service/voice/HotwordDetectionService.java +5 −8 Original line number Diff line number Diff line Loading @@ -363,9 +363,11 @@ public abstract class HotwordDetectionService extends Service * {@link HotwordDetector#startRecognition(ParcelFileDescriptor, AudioFormat, * PersistableBundle)} run} hotword recognition on audio coming from an external connected * microphone. * <p> * Upon invoking the {@code callback}, the system closes {@code audioStream} and sends the * detection result to the {@link HotwordDetector.Callback hotword detector}. * * <p>Upon invoking the {@code callback}, the system will send the detection result to * the {@link HotwordDetector}'s callback. If {@code * options.getBoolean(KEY_SYSTEM_WILL_CLOSE_AUDIO_STREAM_AFTER_CALLBACK, true)} returns true, * the system will also close the {@code audioStream} after {@code callback} is invoked. * * @param audioStream Stream containing audio bytes returned from a microphone * @param audioFormat Format of the supplied audio Loading @@ -375,11 +377,6 @@ public abstract class HotwordDetectionService extends Service * PersistableBundle)}. * @param callback The callback to use for responding to the detection request. */ // TODO(b/324635656): Update Javadoc for 24Q3 release. Change the last paragraph to: // <p>Upon invoking the {@code callback}, the system will send the detection result to // the {@link HotwordDetector}'s callback. If {@code // options.getBoolean(KEY_SYSTEM_WILL_CLOSE_AUDIO_STREAM_AFTER_CALLBACK, true)} returns true, // the system will also close the {@code audioStream} after {@code callback} is invoked. public void onDetect( @NonNull ParcelFileDescriptor audioStream, @NonNull AudioFormat audioFormat, Loading Loading
core/api/system-current.txt +1 −1 Original line number Diff line number Diff line Loading @@ -3348,7 +3348,7 @@ package android.app.wearable { field public static final int STATUS_SERVICE_UNAVAILABLE = 3; // 0x3 field public static final int STATUS_SUCCESS = 1; // 0x1 field public static final int STATUS_UNKNOWN = 0; // 0x0 field public static final int STATUS_UNSUPPORTED = 2; // 0x2 field @Deprecated public static final int STATUS_UNSUPPORTED = 2; // 0x2 field @FlaggedApi("android.app.wearable.enable_data_request_observer_api") public static final int STATUS_UNSUPPORTED_DATA_TYPE = 8; // 0x8 field @FlaggedApi("android.app.wearable.enable_unsupported_operation_status_code") public static final int STATUS_UNSUPPORTED_OPERATION = 6; // 0x6 field public static final int STATUS_WEARABLE_UNAVAILABLE = 4; // 0x4
core/java/android/app/wearable/WearableSensingManager.java +5 −5 Original line number Diff line number Diff line Loading @@ -95,11 +95,12 @@ public class WearableSensingManager { /** * The value of the status code that indicates one or more of the requested events are not * supported. * * @deprecated WearableSensingManager does not deal with events. Use {@link * STATUS_UNSUPPORTED_OPERATION} instead for operations not supported by the implementation of * {@link WearableSensingService}. */ // TODO(b/324635656): Deprecate this status code. Update Javadoc: // @deprecated WearableSensingManager does not deal with events. Use {@link // STATUS_UNSUPPORTED_OPERATION} instead for operations not supported by the implementation of // {@link WearableSensingService}. @Deprecated public static final int STATUS_UNSUPPORTED = 2; /** Loading @@ -121,7 +122,6 @@ public class WearableSensingManager { * The value of the status code that indicates the method called is not supported by the * implementation of {@link WearableSensingService}. */ @FlaggedApi(Flags.FLAG_ENABLE_UNSUPPORTED_OPERATION_STATUS_CODE) public static final int STATUS_UNSUPPORTED_OPERATION = 6; Loading
core/java/android/service/voice/AlwaysOnHotwordDetector.java +5 −9 Original line number Diff line number Diff line Loading @@ -819,19 +819,15 @@ public class AlwaysOnHotwordDetector extends AbstractDetector { /** * Called when the keyphrase is spoken. * * <p>This implicitly stops listening for the keyphrase once it's detected. Clients should * start a recognition again once they are done handling this detection. * <p>If {@code eventPayload.isRecognitionStopped()} returns true, this implicitly stops * listening for the keyphrase once it's detected. Clients should start a recognition again * once they are done handling this detection. * * @param eventPayload Payload data for the detection event. This may contain the trigger * audio, if requested when calling {@link * AlwaysOnHotwordDetector#startRecognition(int)}. */ // TODO(b/324635656): Update Javadoc for 24Q3 release: // 1. Prepend to the first paragraph: // If {@code eventPayload.isRecognitionStopped()} returns true, this... // 2. Append to the description for @param eventPayload: // ...or if the audio comes from {@link // android.service.wearable.WearableSensingService}. * AlwaysOnHotwordDetector#startRecognition(int)} or if the audio comes from the {@link * android.service.wearable.WearableSensingService}. */ public abstract void onDetected(@NonNull EventPayload eventPayload); /** Loading
core/java/android/service/voice/HotwordDetectionService.java +5 −8 Original line number Diff line number Diff line Loading @@ -363,9 +363,11 @@ public abstract class HotwordDetectionService extends Service * {@link HotwordDetector#startRecognition(ParcelFileDescriptor, AudioFormat, * PersistableBundle)} run} hotword recognition on audio coming from an external connected * microphone. * <p> * Upon invoking the {@code callback}, the system closes {@code audioStream} and sends the * detection result to the {@link HotwordDetector.Callback hotword detector}. * * <p>Upon invoking the {@code callback}, the system will send the detection result to * the {@link HotwordDetector}'s callback. If {@code * options.getBoolean(KEY_SYSTEM_WILL_CLOSE_AUDIO_STREAM_AFTER_CALLBACK, true)} returns true, * the system will also close the {@code audioStream} after {@code callback} is invoked. * * @param audioStream Stream containing audio bytes returned from a microphone * @param audioFormat Format of the supplied audio Loading @@ -375,11 +377,6 @@ public abstract class HotwordDetectionService extends Service * PersistableBundle)}. * @param callback The callback to use for responding to the detection request. */ // TODO(b/324635656): Update Javadoc for 24Q3 release. Change the last paragraph to: // <p>Upon invoking the {@code callback}, the system will send the detection result to // the {@link HotwordDetector}'s callback. If {@code // options.getBoolean(KEY_SYSTEM_WILL_CLOSE_AUDIO_STREAM_AFTER_CALLBACK, true)} returns true, // the system will also close the {@code audioStream} after {@code callback} is invoked. public void onDetect( @NonNull ParcelFileDescriptor audioStream, @NonNull AudioFormat audioFormat, Loading