Package 

Interface InstreamAdPlayer

    • Constructor Detail

    • Method Detail

      • prepareAd

         abstract void prepareAd(@NonNull() VideoAd videoAd)

        Prepares player for playing video ad. Implement only this method for prepare Ad.

        Parameters:
        videoAd - object providing information about the advertising video file to be played.
      • playAd

         abstract void playAd(@NonNull() VideoAd videoAd)

        Starts playing ad

        Parameters:
        videoAd - object providing information about the advertising video file to be played.
      • pauseAd

         abstract void pauseAd(@NonNull() VideoAd videoAd)

        Pauses playing ad

        Parameters:
        videoAd - object providing information about the advertising video file to be played.
      • resumeAd

         abstract void resumeAd(@NonNull() VideoAd videoAd)

        Resumes playing ad

        Parameters:
        videoAd - object providing information about the advertising video file to be played.
      • stopAd

         abstract void stopAd(@NonNull() VideoAd videoAd)

        Stops playing ad

        Parameters:
        videoAd - object providing information about the advertising video file to be played.
      • skipAd

         abstract void skipAd(@NonNull() VideoAd videoAd)

        Skips playing ad

        Parameters:
        videoAd - object providing information about the advertising video file to be played.
      • setVolume

         abstract void setVolume(@NonNull() VideoAd videoAd, float volume)

        Sets ad player volume, with 0 being silence and 1 being maximum volume level

        Parameters:
        videoAd - object providing information about the advertising video file to be played.
        volume - volume level in range [0.0, 1.
      • getVolume

         abstract float getVolume(@NonNull() VideoAd videoAd)

        Gets player volume level in range [0.0, 1.0]

        Parameters:
        videoAd - object providing information about the advertising video file to be played.
      • releaseAd

         abstract void releaseAd(@NonNull() VideoAd videoAd)

        Releases ad player object

        Parameters:
        videoAd - object providing information about the advertising video file to be played.
      • setInstreamAdPlayerListener

         abstract void setInstreamAdPlayerListener(@Nullable() InstreamAdPlayerListener instreamAdPlayerListener)

        Sets listener for ad player events. For each event of the instream ad player, the corresponding callback must be called on this object.

        Parameters:
        instreamAdPlayerListener - Listener for ad player events
      • getAdDuration

         abstract long getAdDuration(@NonNull() VideoAd videoAd)

        Gets ad video duration

        Parameters:
        videoAd - object providing information about the advertising video file to be played.
      • getAdPosition

         abstract long getAdPosition(@NonNull() VideoAd videoAd)

        Gets current ad video position

        Parameters:
        videoAd - object providing information about the advertising video file to be played.
      • isPlayingAd

         abstract boolean isPlayingAd(@NonNull() VideoAd videoAd)

        Gets value indicating whether player is playing ad

        Parameters:
        videoAd - object providing information about the advertising video file to be played.