Record Class MovieData

java.lang.Object
java.lang.Record
net.ygbstudio.jbrave.core.domain.dto.web.MovieData
Record Components:
name - The title of the movie.
description - A brief summary or description of the movie's plot.
url - A URL where more information about the movie can be found.
thumbnail - A thumbnail image representing the movie.
release - The release date or year of the movie.
directors - A list of people who directed the movie.
actors - A list of actors who appear in the movie.
rating - The rating information for the movie.
duration - The duration of the movie in a human-readable format.
genre - A list of genres that describe the movie.
query - The original search query that returned this movie result.

public record MovieData(String name, String description, String url, Thumbnail thumbnail, String release, List<Person> directors, List<Person> actors, Rating rating, String duration, List<String> genre, String query) extends Record
Represents detailed information about a movie in search results. This is used in the Brave Search API to provide structured data about movies that match the user's query.
  • Constructor Details

    • MovieData

      public MovieData(String name, String description, String url, Thumbnail thumbnail, String release, List<Person> directors, List<Person> actors, Rating rating, String duration, List<String> genre, String query)
      Creates an instance of a MovieData record class.
      Parameters:
      name - the value for the name record component
      description - the value for the description record component
      url - the value for the url record component
      thumbnail - the value for the thumbnail record component
      release - the value for the release record component
      directors - the value for the directors record component
      actors - the value for the actors record component
      rating - the value for the rating record component
      duration - the value for the duration record component
      genre - the value for the genre record component
      query - the value for the query record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • name

      public String name()
      Returns the value of the name record component.
      Returns:
      the value of the name record component
    • description

      public String description()
      Returns the value of the description record component.
      Returns:
      the value of the description record component
    • url

      public String url()
      Returns the value of the url record component.
      Returns:
      the value of the url record component
    • thumbnail

      public Thumbnail thumbnail()
      Returns the value of the thumbnail record component.
      Returns:
      the value of the thumbnail record component
    • release

      public String release()
      Returns the value of the release record component.
      Returns:
      the value of the release record component
    • directors

      public List<Person> directors()
      Returns the value of the directors record component.
      Returns:
      the value of the directors record component
    • actors

      public List<Person> actors()
      Returns the value of the actors record component.
      Returns:
      the value of the actors record component
    • rating

      public Rating rating()
      Returns the value of the rating record component.
      Returns:
      the value of the rating record component
    • duration

      public String duration()
      Returns the value of the duration record component.
      Returns:
      the value of the duration record component
    • genre

      public List<String> genre()
      Returns the value of the genre record component.
      Returns:
      the value of the genre record component
    • query

      public String query()
      Returns the value of the query record component.
      Returns:
      the value of the query record component