Class MoviesAPI


  • public final class MoviesAPI
    extends QueryResource
    Implementation of a connector for the remote API's Movies endpoint.


    Provides static access to all routes of this endpoint which may be used to gather information about specific movies.

    • Method Detail

      • get

        public static com.fasterxml.jackson.databind.JsonNode get​(@Nonnull
                                                                  APIConnection con,
                                                                  long id)
                                                           throws APIException
        Returns detailed information for a specific movie as raw JSON.


        Corresponds to remote API route: [GET] /movies/{id}

        Parameters:
        con - Initialized connection to be used for API communication
        id - The TheTVDB.com movie ID
        Returns:
        JSON object containing detailed information for a specific movie
        Throws:
        APIException - If an exception with the remote API occurs, e.g. authentication failure, IO error, the given movie ID does not exist, etc.
      • getMovieUpdates

        public static com.fasterxml.jackson.databind.JsonNode getMovieUpdates​(@Nonnull
                                                                              APIConnection con,
                                                                              @CheckForNull
                                                                              QueryParameters params)
                                                                       throws APIException
        Returns a list of ID's of all movies, that have been updated since a specific time, as raw JSON.


        Corresponds to remote API route: [GET] /movieupdates

        Parameters:
        con - Initialized connection to be used for API communication
        params - Object containing key/value pairs of query parameters. Has to specify a proper since parameter at least.
        Returns:
        JSON object containing the ID's of movies that have been updated beginning at the specified epoch time
        Throws:
        APIException - If an exception with the remote API occurs, e.g. authentication failure, IO error, resource not found, etc.