Class Catalog

  • All Implemented Interfaces:
    Component
    Direct Known Subclasses:
    AbstractOfflineCatalog

    @Emits(events={"error","account","videoDownloadStarted","videoDownloadCompleted","videoDownloadCancelled","videoDownloadFailed"})
    @ListensFor(events={})
    public class Catalog
    extends AbstractComponent
    The Catalog class provides asynchronous methods for retrieving information about videos from Brightcove's Edge API services.

    Network requests such as those implemented by the Catalog class sometimes fail. If the request succeeds, the listener's onVideo() method will be invoked. If an error occurs during the execution of the request, the listener's onError() method will be invoked.

    • Field Detail

      • DEFAULT_EDGE_BASE_URL

        public static final java.lang.String DEFAULT_EDGE_BASE_URL
        See Also:
        Constant Field Values
      • DEFAULT_EPA_BASE_URL

        public static final java.lang.String DEFAULT_EPA_BASE_URL
        See Also:
        Constant Field Values
      • INSTANCE

        protected static Catalog INSTANCE
    • Constructor Detail

      • Catalog

        @Deprecated
        public Catalog​(@NonNull
                       EventEmitter eventEmitter,
                       @NonNull
                       java.lang.String account,
                       @NonNull
                       java.lang.String policy)
        Deprecated.
        Please use Catalog.Builder to create the Catalog.
      • Catalog

        @Deprecated
        public Catalog​(@NonNull
                       EventEmitter eventEmitter,
                       @NonNull
                       java.lang.String account,
                       @NonNull
                       java.lang.String policy,
                       @NonNull
                       java.lang.String baseURL)
        Deprecated.
        Please use Catalog.Builder to create the Catalog.
    • Method Detail

      • getInstance

        public static Catalog getInstance()
      • empty

        public static Catalog empty()
      • findPlaylistByID

        public void findPlaylistByID​(@NonNull
                                     java.lang.String playlistID,
                                     @NonNull
                                     HttpRequestConfig httpRequestConfig,
                                     @NonNull
                                     PlaylistListener playlistListener)
        Retrieves a Playlist from the Playback API service by its playlist ID.

        If your VideoCloud configuration requires a Brightcove Authorization token, provide it using HttpRequestConfig.Builder.setBrightcoveAuthorizationToken(String). This token will be configured when creating the Video object, and it will be used when requesting the Video license.

        Parameters:
        playlistID - string containing the ID of the playlist to find.
        httpRequestConfig - a configuration class with values used in the request.
        playlistListener - A callback which will be invoked when the request finishes or an error occurs.
      • findPlaylistByID

        public void findPlaylistByID​(@NonNull
                                     java.lang.String playlistID,
                                     @NonNull
                                     PlaylistListener playlistListener)
        Retrieves a Playlist from the Playback API service by its playlist ID.
        Parameters:
        playlistID - string containing the ID of the playlist to find.
        playlistListener - A callback which will be invoked when the request finishes or an error occurs.
      • findPlaylistByID

        @Deprecated
        public void findPlaylistByID​(@NonNull
                                     java.lang.String playlistID,
                                     @Nullable
                                     java.util.Map<java.lang.String,​java.lang.String> headers,
                                     @Nullable
                                     java.util.Map<java.lang.String,​java.lang.String> queryParameters,
                                     @NonNull
                                     PlaylistListener playlistListener)
      • findPlaylistByReferenceID

        public void findPlaylistByReferenceID​(@NonNull
                                              java.lang.String referenceID,
                                              @NonNull
                                              HttpRequestConfig httpRequestConfig,
                                              @NonNull
                                              PlaylistListener playlistListener)
        Retrieves a Playlist from the Playback API service by its reference ID, a customer supplied unique identifier.

        If your VideoCloud configuration requires a Brightcove Authorization token, provide it using HttpRequestConfig.Builder.setBrightcoveAuthorizationToken(String). This token will be configured when creating the Video object, and it will be used when requesting the Video license.

        Parameters:
        referenceID - string containing the reference ID of the playlist to find.
        httpRequestConfig - a configuration class with values used in the request.
        playlistListener - A callback which will be invoked when the request finishes or an error occurs.
      • findPlaylistByReferenceID

        public void findPlaylistByReferenceID​(@NonNull
                                              java.lang.String referenceID,
                                              @NonNull
                                              PlaylistListener playlistListener)
        Retrieves a Playlist from the Playback API service by its reference ID, a customer supplied unique identifier.
        Parameters:
        referenceID - string containing the reference ID of the playlist to find.
        playlistListener - A callback which will be invoked when the request finishes or an error occurs.
      • findVideoByID

        public void findVideoByID​(@NonNull
                                  java.lang.String videoID,
                                  @NonNull
                                  HttpRequestConfig httpRequestConfig,
                                  @NonNull
                                  VideoListener videoListener)
        Retrieves a Video from the Playback API service by its video ID.

        If your VideoCloud configuration requires a Brightcove Authorization token, provide it using HttpRequestConfig.Builder.setBrightcoveAuthorizationToken(String). This token will be configured when creating the Video object, and it will be used when requesting the Video license.

        Parameters:
        videoID - string containing the ID of the video to find.
        httpRequestConfig - a configuration class with values used in the request.
        videoListener - A callback which will be invoked when the request finishes or an error occurs.
      • findVideoByID

        public void findVideoByID​(@NonNull
                                  java.lang.String videoID,
                                  @NonNull
                                  VideoListener videoListener)
        Retrieves a Video from the Playback API service by its video ID.
        Parameters:
        videoID - string containing the ID of the video to find.
        videoListener - A callback which will be invoked when the request finishes or an error occurs.
      • findVideoByID

        @Deprecated
        public void findVideoByID​(@NonNull
                                  java.lang.String videoID,
                                  @Nullable
                                  java.util.Map<java.lang.String,​java.lang.String> headers,
                                  @Nullable
                                  java.util.Map<java.lang.String,​java.lang.String> queryParameters,
                                  @NonNull
                                  VideoListener videoListener)
      • findVideoByReferenceID

        public void findVideoByReferenceID​(@NonNull
                                           java.lang.String referenceID,
                                           @NonNull
                                           HttpRequestConfig httpRequestConfig,
                                           @NonNull
                                           VideoListener videoListener)
        Retrieves a Video from the Playback API service by its reference ID, a customer supplied unique identifier.

        If your VideoCloud configuration requires a Brightcove Authorization token, provide it using HttpRequestConfig.Builder.setBrightcoveAuthorizationToken(String). This token will be configured when creating the Video object, and it will be used when requesting the Video license.

        Parameters:
        referenceID - string containing the reference ID of the video to find.
        httpRequestConfig - a configuration class with values used in the request.
        videoListener - A callback which will be invoked when the request finishes or an error occurs.
      • findVideoByReferenceID

        public void findVideoByReferenceID​(@NonNull
                                           java.lang.String referenceID,
                                           @NonNull
                                           VideoListener videoListener)
        Retrieves a Video from the Playback API service by its reference ID, a customer supplied unique identifier.
        Parameters:
        referenceID - string containing the reference ID of the video to find.
        videoListener - A callback which will be invoked when the request finishes or an error occurs.
      • findVideoByReferenceID

        @Deprecated
        public void findVideoByReferenceID​(@NonNull
                                           java.lang.String referenceID,
                                           @Nullable
                                           java.util.Map<java.lang.String,​java.lang.String> headers,
                                           @Nullable
                                           java.util.Map<java.lang.String,​java.lang.String> queryParameters,
                                           @NonNull
                                           VideoListener videoListener)
      • getProperties

        public java.util.Map<java.lang.String,​java.lang.String> getProperties()
        Get the Map of properties for this Offline Catalog
        Returns:
        The map of optional properties