From a433163b5167d5868ba0d3e200a1f45c65b643dd Mon Sep 17 00:00:00 2001 From: ibaker Date: Fri, 29 Apr 2022 09:26:18 +0100 Subject: [PATCH] Prefix @ContentType values with CONTENT_ PiperOrigin-RevId: 445356625 --- .../java/com/google/android/exoplayer2/C.java | 49 ++++++++++++++++--- 1 file changed, 41 insertions(+), 8 deletions(-) diff --git a/library/common/src/main/java/com/google/android/exoplayer2/C.java b/library/common/src/main/java/com/google/android/exoplayer2/C.java index 5283c073c0..6b0d4ce6f7 100644 --- a/library/common/src/main/java/com/google/android/exoplayer2/C.java +++ b/library/common/src/main/java/com/google/android/exoplayer2/C.java @@ -728,26 +728,59 @@ public final class C { public static final String LANGUAGE_UNDETERMINED = "und"; /** - * Represents a streaming or other media type. One of {@link #TYPE_DASH}, {@link #TYPE_SS}, {@link - * #TYPE_HLS}, {@link #TYPE_RTSP} or {@link #TYPE_OTHER}. + * Represents a streaming or other media type. One of: + * + * */ // @Target list includes both 'default' targets and TYPE_USE, to ensure backwards compatibility // with Kotlin usages from before TYPE_USE was added. @Documented @Retention(RetentionPolicy.SOURCE) @Target({FIELD, METHOD, PARAMETER, LOCAL_VARIABLE, TYPE_USE}) - @IntDef({TYPE_DASH, TYPE_SS, TYPE_HLS, TYPE_RTSP, TYPE_OTHER}) + @IntDef({ + CONTENT_TYPE_DASH, + CONTENT_TYPE_SS, + CONTENT_TYPE_HLS, + CONTENT_TYPE_RTSP, + CONTENT_TYPE_OTHER + }) public @interface ContentType {} /** Value representing a DASH manifest. */ - public static final int TYPE_DASH = 0; + public static final int CONTENT_TYPE_DASH = 0; + /** + * @deprecated Use {@link #CONTENT_TYPE_DASH} instead. + */ + @Deprecated public static final int TYPE_DASH = CONTENT_TYPE_DASH; /** Value representing a Smooth Streaming manifest. */ - public static final int TYPE_SS = 1; + public static final int CONTENT_TYPE_SS = 1; + /** + * @deprecated Use {@link #CONTENT_TYPE_SS} instead. + */ + @Deprecated public static final int TYPE_SS = CONTENT_TYPE_SS; /** Value representing an HLS manifest. */ - public static final int TYPE_HLS = 2; + public static final int CONTENT_TYPE_HLS = 2; + /** + * @deprecated Use {@link #CONTENT_TYPE_HLS} instead. + */ + @Deprecated public static final int TYPE_HLS = CONTENT_TYPE_HLS; /** Value representing an RTSP stream. */ - public static final int TYPE_RTSP = 3; + public static final int CONTENT_TYPE_RTSP = 3; + /** + * @deprecated Use {@link #CONTENT_TYPE_RTSP} instead. + */ + @Deprecated public static final int TYPE_RTSP = CONTENT_TYPE_RTSP; /** Value representing files other than DASH, HLS or Smooth Streaming manifests, or RTSP URIs. */ - public static final int TYPE_OTHER = 4; + public static final int CONTENT_TYPE_OTHER = 4; + /** + * @deprecated Use {@link #CONTENT_TYPE_OTHER} instead. + */ + @Deprecated public static final int TYPE_OTHER = CONTENT_TYPE_OTHER; /** A return value for methods where the end of an input was encountered. */ public static final int RESULT_END_OF_INPUT = -1;