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

Commit f98a4f2a authored by Conrad Chen's avatar Conrad Chen
Browse files

TIF: add TvContract.isRecordedProgramUri() method

Test: cts-tradefed run cts -m CtsTvTestCases
Bug: 37577698
Change-Id: I91bfae8db1c3fa2e50313b0501423aefae37366f
parent 8bebf339
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -24474,6 +24474,7 @@ package android.media.tv {
    method public static boolean isChannelUriForPassthroughInput(android.net.Uri);
    method public static boolean isChannelUriForTunerInput(android.net.Uri);
    method public static boolean isProgramUri(android.net.Uri);
    method public static boolean isRecordedProgramUri(android.net.Uri);
    method public static void requestChannelBrowsable(android.content.Context, long);
    field public static final java.lang.String ACTION_INITIALIZE_PROGRAMS = "android.media.tv.action.INITIALIZE_PROGRAMS";
    field public static final java.lang.String ACTION_PREVIEW_PROGRAM_ADDED_TO_WATCH_NEXT = "android.media.tv.action.PREVIEW_PROGRAM_ADDED_TO_WATCH_NEXT";
+1 −0
Original line number Diff line number Diff line
@@ -26468,6 +26468,7 @@ package android.media.tv {
    method public static boolean isChannelUriForPassthroughInput(android.net.Uri);
    method public static boolean isChannelUriForTunerInput(android.net.Uri);
    method public static boolean isProgramUri(android.net.Uri);
    method public static boolean isRecordedProgramUri(android.net.Uri);
    method public static void requestChannelBrowsable(android.content.Context, long);
    field public static final java.lang.String ACTION_CHANNEL_BROWSABLE_REQUESTED = "android.media.tv.action.CHANNEL_BROWSABLE_REQUESTED";
    field public static final java.lang.String ACTION_INITIALIZE_PROGRAMS = "android.media.tv.action.INITIALIZE_PROGRAMS";
+1 −0
Original line number Diff line number Diff line
@@ -24584,6 +24584,7 @@ package android.media.tv {
    method public static boolean isChannelUriForPassthroughInput(android.net.Uri);
    method public static boolean isChannelUriForTunerInput(android.net.Uri);
    method public static boolean isProgramUri(android.net.Uri);
    method public static boolean isRecordedProgramUri(android.net.Uri);
    method public static void requestChannelBrowsable(android.content.Context, long);
    field public static final java.lang.String ACTION_INITIALIZE_PROGRAMS = "android.media.tv.action.INITIALIZE_PROGRAMS";
    field public static final java.lang.String ACTION_PREVIEW_PROGRAM_ADDED_TO_WATCH_NEXT = "android.media.tv.action.PREVIEW_PROGRAM_ADDED_TO_WATCH_NEXT";
+7 −0
Original line number Diff line number Diff line
@@ -730,6 +730,13 @@ public final class TvContract {
        return isTvUri(uri) && isTwoSegmentUriStartingWith(uri, PATH_PROGRAM);
    }

    /**
     * Returns {@code true}, if {@code uri} is a recorded program URI.
     */
    public static boolean isRecordedProgramUri(Uri uri) {
        return isTvUri(uri) && isTwoSegmentUriStartingWith(uri, PATH_RECORDED_PROGRAM);
    }

    /**
     * Requests to make a channel browsable.
     *