diff --git a/api/current.txt b/api/current.txt index 7207d88632d90..41e17b7d21d0a 100644 --- a/api/current.txt +++ b/api/current.txt @@ -24705,6 +24705,8 @@ package android.media.tv { field public static final java.lang.String COLUMN_LONG_DESCRIPTION = "long_description"; field public static final java.lang.String COLUMN_POSTER_ART_URI = "poster_art_uri"; field public static final java.lang.String COLUMN_RECORDING_PROHIBITED = "recording_prohibited"; + field public static final java.lang.String COLUMN_REVIEW_RATING = "review_rating"; + field public static final java.lang.String COLUMN_REVIEW_RATING_STYLE = "review_rating_style"; field public static final java.lang.String COLUMN_SEARCHABLE = "searchable"; field public static final java.lang.String COLUMN_SEASON_DISPLAY_NUMBER = "season_display_number"; field public static final deprecated java.lang.String COLUMN_SEASON_NUMBER = "season_number"; @@ -24719,6 +24721,9 @@ package android.media.tv { field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/program"; field public static final java.lang.String CONTENT_TYPE = "vnd.android.cursor.dir/program"; field public static final android.net.Uri CONTENT_URI; + field public static final int REVIEW_RATING_STYLE_PERCENTAGE = 2; // 0x2 + field public static final int REVIEW_RATING_STYLE_STARS = 0; // 0x0 + field public static final int REVIEW_RATING_STYLE_THUMBS_UP_DOWN = 1; // 0x1 } public static final class TvContract.Programs.Genres { @@ -24765,6 +24770,8 @@ package android.media.tv { field public static final java.lang.String COLUMN_RECORDING_DATA_URI = "recording_data_uri"; field public static final java.lang.String COLUMN_RECORDING_DURATION_MILLIS = "recording_duration_millis"; field public static final java.lang.String COLUMN_RECORDING_EXPIRE_TIME_UTC_MILLIS = "recording_expire_time_utc_millis"; + field public static final java.lang.String COLUMN_REVIEW_RATING = "review_rating"; + field public static final java.lang.String COLUMN_REVIEW_RATING_STYLE = "review_rating_style"; field public static final java.lang.String COLUMN_SEARCHABLE = "searchable"; field public static final java.lang.String COLUMN_SEASON_DISPLAY_NUMBER = "season_display_number"; field public static final java.lang.String COLUMN_SEASON_TITLE = "season_title"; @@ -24778,6 +24785,9 @@ package android.media.tv { field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/recorded_program"; field public static final java.lang.String CONTENT_TYPE = "vnd.android.cursor.dir/recorded_program"; field public static final android.net.Uri CONTENT_URI; + field public static final int REVIEW_RATING_STYLE_PERCENTAGE = 2; // 0x2 + field public static final int REVIEW_RATING_STYLE_STARS = 0; // 0x0 + field public static final int REVIEW_RATING_STYLE_THUMBS_UP_DOWN = 1; // 0x1 } public static final class TvContract.WatchNextPrograms implements android.media.tv.TvContract.BaseTvColumns { diff --git a/api/system-current.txt b/api/system-current.txt index b561d45af71f8..489567ec69aae 100644 --- a/api/system-current.txt +++ b/api/system-current.txt @@ -26685,6 +26685,8 @@ package android.media.tv { field public static final java.lang.String COLUMN_LONG_DESCRIPTION = "long_description"; field public static final java.lang.String COLUMN_POSTER_ART_URI = "poster_art_uri"; field public static final java.lang.String COLUMN_RECORDING_PROHIBITED = "recording_prohibited"; + field public static final java.lang.String COLUMN_REVIEW_RATING = "review_rating"; + field public static final java.lang.String COLUMN_REVIEW_RATING_STYLE = "review_rating_style"; field public static final java.lang.String COLUMN_SEARCHABLE = "searchable"; field public static final java.lang.String COLUMN_SEASON_DISPLAY_NUMBER = "season_display_number"; field public static final deprecated java.lang.String COLUMN_SEASON_NUMBER = "season_number"; @@ -26699,6 +26701,9 @@ package android.media.tv { field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/program"; field public static final java.lang.String CONTENT_TYPE = "vnd.android.cursor.dir/program"; field public static final android.net.Uri CONTENT_URI; + field public static final int REVIEW_RATING_STYLE_PERCENTAGE = 2; // 0x2 + field public static final int REVIEW_RATING_STYLE_STARS = 0; // 0x0 + field public static final int REVIEW_RATING_STYLE_THUMBS_UP_DOWN = 1; // 0x1 } public static final class TvContract.Programs.Genres { @@ -26745,6 +26750,8 @@ package android.media.tv { field public static final java.lang.String COLUMN_RECORDING_DATA_URI = "recording_data_uri"; field public static final java.lang.String COLUMN_RECORDING_DURATION_MILLIS = "recording_duration_millis"; field public static final java.lang.String COLUMN_RECORDING_EXPIRE_TIME_UTC_MILLIS = "recording_expire_time_utc_millis"; + field public static final java.lang.String COLUMN_REVIEW_RATING = "review_rating"; + field public static final java.lang.String COLUMN_REVIEW_RATING_STYLE = "review_rating_style"; field public static final java.lang.String COLUMN_SEARCHABLE = "searchable"; field public static final java.lang.String COLUMN_SEASON_DISPLAY_NUMBER = "season_display_number"; field public static final java.lang.String COLUMN_SEASON_TITLE = "season_title"; @@ -26758,6 +26765,9 @@ package android.media.tv { field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/recorded_program"; field public static final java.lang.String CONTENT_TYPE = "vnd.android.cursor.dir/recorded_program"; field public static final android.net.Uri CONTENT_URI; + field public static final int REVIEW_RATING_STYLE_PERCENTAGE = 2; // 0x2 + field public static final int REVIEW_RATING_STYLE_STARS = 0; // 0x0 + field public static final int REVIEW_RATING_STYLE_THUMBS_UP_DOWN = 1; // 0x1 } public static final class TvContract.WatchNextPrograms implements android.media.tv.TvContract.BaseTvColumns { diff --git a/api/test-current.txt b/api/test-current.txt index fd17070372927..27b266ded7a7f 100644 --- a/api/test-current.txt +++ b/api/test-current.txt @@ -24818,6 +24818,8 @@ package android.media.tv { field public static final java.lang.String COLUMN_LONG_DESCRIPTION = "long_description"; field public static final java.lang.String COLUMN_POSTER_ART_URI = "poster_art_uri"; field public static final java.lang.String COLUMN_RECORDING_PROHIBITED = "recording_prohibited"; + field public static final java.lang.String COLUMN_REVIEW_RATING = "review_rating"; + field public static final java.lang.String COLUMN_REVIEW_RATING_STYLE = "review_rating_style"; field public static final java.lang.String COLUMN_SEARCHABLE = "searchable"; field public static final java.lang.String COLUMN_SEASON_DISPLAY_NUMBER = "season_display_number"; field public static final deprecated java.lang.String COLUMN_SEASON_NUMBER = "season_number"; @@ -24832,6 +24834,9 @@ package android.media.tv { field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/program"; field public static final java.lang.String CONTENT_TYPE = "vnd.android.cursor.dir/program"; field public static final android.net.Uri CONTENT_URI; + field public static final int REVIEW_RATING_STYLE_PERCENTAGE = 2; // 0x2 + field public static final int REVIEW_RATING_STYLE_STARS = 0; // 0x0 + field public static final int REVIEW_RATING_STYLE_THUMBS_UP_DOWN = 1; // 0x1 } public static final class TvContract.Programs.Genres { @@ -24878,6 +24883,8 @@ package android.media.tv { field public static final java.lang.String COLUMN_RECORDING_DATA_URI = "recording_data_uri"; field public static final java.lang.String COLUMN_RECORDING_DURATION_MILLIS = "recording_duration_millis"; field public static final java.lang.String COLUMN_RECORDING_EXPIRE_TIME_UTC_MILLIS = "recording_expire_time_utc_millis"; + field public static final java.lang.String COLUMN_REVIEW_RATING = "review_rating"; + field public static final java.lang.String COLUMN_REVIEW_RATING_STYLE = "review_rating_style"; field public static final java.lang.String COLUMN_SEARCHABLE = "searchable"; field public static final java.lang.String COLUMN_SEASON_DISPLAY_NUMBER = "season_display_number"; field public static final java.lang.String COLUMN_SEASON_TITLE = "season_title"; @@ -24891,6 +24898,9 @@ package android.media.tv { field public static final java.lang.String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/recorded_program"; field public static final java.lang.String CONTENT_TYPE = "vnd.android.cursor.dir/recorded_program"; field public static final android.net.Uri CONTENT_URI; + field public static final int REVIEW_RATING_STYLE_PERCENTAGE = 2; // 0x2 + field public static final int REVIEW_RATING_STYLE_STARS = 0; // 0x0 + field public static final int REVIEW_RATING_STYLE_THUMBS_UP_DOWN = 1; // 0x1 } public static final class TvContract.WatchNextPrograms implements android.media.tv.TvContract.BaseTvColumns { diff --git a/media/java/android/media/tv/TvContract.java b/media/java/android/media/tv/TvContract.java index e82dd8255d213..6635b5f1aa459 100644 --- a/media/java/android/media/tv/TvContract.java +++ b/media/java/android/media/tv/TvContract.java @@ -589,6 +589,36 @@ public final class TvContract { * @hide */ interface ProgramColumns { + /** @hide */ + @IntDef({ + REVIEW_RATING_STYLE_STARS, + REVIEW_RATING_STYLE_THUMBS_UP_DOWN, + REVIEW_RATING_STYLE_PERCENTAGE, + }) + @Retention(RetentionPolicy.SOURCE) + @interface ReviewRatingStyle {} + + /** + * The review rating style for five star rating. + * + * @see #COLUMN_REVIEW_RATING_STYLE + */ + int REVIEW_RATING_STYLE_STARS = 0; + + /** + * The review rating style for thumbs-up and thumbs-down rating. + * + * @see #COLUMN_REVIEW_RATING_STYLE + */ + int REVIEW_RATING_STYLE_THUMBS_UP_DOWN = 1; + + /** + * The review rating style for 0 to 100 point system. + * + * @see #COLUMN_REVIEW_RATING_STYLE + */ + int REVIEW_RATING_STYLE_PERCENTAGE = 2; + /** * The title of this TV program. * @@ -851,6 +881,33 @@ public final class TvContract { *

Type: INTEGER */ String COLUMN_VERSION_NUMBER = "version_number"; + + /** + * The review rating score style used for {@link #COLUMN_REVIEW_RATING}. + * + *

The value should match one of the followings: {@link #REVIEW_RATING_STYLE_STARS}, + * {@link #REVIEW_RATING_STYLE_THUMBS_UP_DOWN}, and {@link #REVIEW_RATING_STYLE_PERCENTAGE}. + * + *

Type: INTEGER + * @see #COLUMN_REVIEW_RATING + */ + String COLUMN_REVIEW_RATING_STYLE = "review_rating_style"; + + /** + * The review rating score for this program. + * + *

The format of the value is dependent on {@link #COLUMN_REVIEW_RATING_STYLE}. If the + * style is {@link #REVIEW_RATING_STYLE_STARS}, the value should be a real number between + * 0.0 and 5.0. (e.g. "4.5") If the style is {@link #REVIEW_RATING_STYLE_THUMBS_UP_DOWN}, + * the value should be two integers, one for thumbs-up count and the other for thumbs-down + * count, with a comma between them. (e.g. "200,40") If the style is + * {@link #REVIEW_RATING_STYLE_PERCENTAGE}, the value shoule be a real number between 0 and + * 100. (e.g. "99.9") + * + *

Type: TEXT + * @see #COLUMN_REVIEW_RATING_STYLE + */ + String COLUMN_REVIEW_RATING = "review_rating"; } /** @@ -1096,36 +1153,6 @@ public final class TvContract { */ int INTERACTION_TYPE_VIEWERS = 6; - /** @hide */ - @IntDef({ - REVIEW_RATING_STYLE_STARS, - REVIEW_RATING_STYLE_THUMBS_UP_DOWN, - REVIEW_RATING_STYLE_PERCENTAGE, - }) - @Retention(RetentionPolicy.SOURCE) - public @interface ReviewRatingStyle {} - - /** - * The review rating style for five star rating. - * - * @see #COLUMN_REVIEW_RATING_STYLE - */ - int REVIEW_RATING_STYLE_STARS = 0; - - /** - * The review rating style for thumbs-up and thumbs-down rating. - * - * @see #COLUMN_REVIEW_RATING_STYLE - */ - int REVIEW_RATING_STYLE_THUMBS_UP_DOWN = 1; - - /** - * The review rating style for 0 to 100 point system. - * - * @see #COLUMN_REVIEW_RATING_STYLE - */ - int REVIEW_RATING_STYLE_PERCENTAGE = 2; - /** * The type of this program content. * @@ -1374,33 +1401,6 @@ public final class TvContract { */ String COLUMN_AUTHOR = "author"; - /** - * The review rating score style used for {@link #COLUMN_REVIEW_RATING}. - * - *

The value should match one of the followings: {@link #REVIEW_RATING_STYLE_STARS}, - * {@link #REVIEW_RATING_STYLE_THUMBS_UP_DOWN}, and {@link #REVIEW_RATING_STYLE_PERCENTAGE}. - * - *

Type: INTEGER - * @see #COLUMN_REVIEW_RATING - */ - String COLUMN_REVIEW_RATING_STYLE = "review_rating_style"; - - /** - * The review rating score for this program. - * - *

The format of the value is dependent on {@link #COLUMN_REVIEW_RATING_STYLE}. If the - * style is {@link #REVIEW_RATING_STYLE_STARS}, the value should be a real number between - * 0.0 and 5.0. (e.g. "4.5") If the style is {@link #REVIEW_RATING_STYLE_THUMBS_UP_DOWN}, - * the value should be two integers, one for thumbs-up count and the other for thumbs-down - * count, with a comma between them. (e.g. "200,40") If the style is - * {@link #REVIEW_RATING_STYLE_PERCENTAGE}, the value shoule be a real number between 0 and - * 100. (e.g. "99.9") - * - *

Type: TEXT - * @see #COLUMN_REVIEW_RATING_STYLE - */ - String COLUMN_REVIEW_RATING = "review_rating"; - /** * The flag indicating whether this TV program is browsable or not. *