Class MultiControllerPlaylist.Builder

    • Constructor Detail

      • Builder

        public Builder​(@NonNull
                       PlayerView playerView)
        Creates an instance of the Builder.
        Parameters:
        playerView - the PlayerView from which to use the context.
      • Builder

        public Builder​(@NonNull
                       Context context)
        Creates an instance of the Builder.
        Parameters:
        context - the Context to use when creating PlayerController instances.
    • Method Detail

      • nextItemThresholdMs

        public MultiControllerPlaylist.Builder nextItemThresholdMs​(int nextItemThresholdMs)
        Sets the nextItemThreshold in milliseconds.
        Parameters:
        nextItemThresholdMs - the next item threshold in milliseconds
        Returns:
        the Builder
      • backPlayers

        public MultiControllerPlaylist.Builder backPlayers​(int backPlayersCount)
        Sets the number of "back players". This is the number of concurrently maintained background players for past playlist items. Defaults to 0.
        Parameters:
        backPlayersCount - the number of back players to use
        Returns:
        the Builder
      • forwardPlayers

        public MultiControllerPlaylist.Builder forwardPlayers​(int forwardPlayersCount)
        Sets the number of "forward players". This is the number of concurrently maintained background players for future playlist items. Defaults to 1.
        Parameters:
        forwardPlayersCount - the number of forward players to use
        Returns:
        the Builder
      • playBackground

        public MultiControllerPlaylist.Builder playBackground​(boolean playBackground)
        Sets the flag indicating whether or not to immediately start playing the background PlayerControllers. If false, the PlayerController will be in paused state until it is attached.
        Parameters:
        playBackground - whether to allow background playback or not.
        Returns:
        the Builder
      • justEnableAnalyticsForCurrentItem

        public MultiControllerPlaylist.Builder justEnableAnalyticsForCurrentItem​(boolean justEnableAnalyticsForCurrentItem)
        If set to true the analytics sessions are just enabled for current item in the playlist.
        Parameters:
        justEnableAnalyticsForCurrentItem - the value
        Returns:
        the Builder