summaryrefslogtreecommitdiff
path: root/core/java/android/hardware/HardwareBuffer.java
diff options
context:
space:
mode:
authorTor Norbye <tnorbye@google.com>2017-11-16 14:47:04 -0800
committerTor Norbye <tnorbye@google.com>2017-12-08 20:54:50 -0800
commitf740c7ea0810c186e84e989b72012ed7152a7834 (patch)
tree9825df6e0720f80dcf4bbee485283d1236c05583 /core/java/android/hardware/HardwareBuffer.java
parent15ee5ebf75acb6b5d3f1b65b2ca90169ce319b29 (diff)
Switch @IntDef from long to int, and add @LongDef
This CL mirrors changes made to the android.support.annotation version of IntDef, to keep the usage and semantics identical (though the internal version of @IntDef and @LongDef are of course hidden and not part of the SDK.) Test: These annotations have source retention and therefore have no runtime impact; the change was compiling the SDK. Change-Id: Idaf47e8d983c88be1bd8f938615c86611014b45a
Diffstat (limited to 'core/java/android/hardware/HardwareBuffer.java')
-rw-r--r--core/java/android/hardware/HardwareBuffer.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/core/java/android/hardware/HardwareBuffer.java b/core/java/android/hardware/HardwareBuffer.java
index 7049628b3590..b111ad30f27d 100644
--- a/core/java/android/hardware/HardwareBuffer.java
+++ b/core/java/android/hardware/HardwareBuffer.java
@@ -17,6 +17,7 @@
package android.hardware;
import android.annotation.IntDef;
+import android.annotation.LongDef;
import android.annotation.NonNull;
import android.os.Parcel;
import android.os.Parcelable;
@@ -70,7 +71,7 @@ public final class HardwareBuffer implements Parcelable, AutoCloseable {
/** @hide */
@Retention(RetentionPolicy.SOURCE)
- @IntDef(flag = true, value = {USAGE_CPU_READ_RARELY, USAGE_CPU_READ_OFTEN,
+ @LongDef(flag = true, value = {USAGE_CPU_READ_RARELY, USAGE_CPU_READ_OFTEN,
USAGE_CPU_WRITE_RARELY, USAGE_CPU_WRITE_OFTEN, USAGE_GPU_SAMPLED_IMAGE,
USAGE_GPU_COLOR_OUTPUT, USAGE_PROTECTED_CONTENT, USAGE_VIDEO_ENCODE,
USAGE_GPU_DATA_BUFFER, USAGE_SENSOR_DIRECT_DATA})