Record Class FestivalPerformanceRequest

java.lang.Object
java.lang.Record
org.localify.festival.dto.request.FestivalPerformanceRequest
Record Components:
artists - The list of artists in the performance.
stageName - The name of the stage.
stageAddress - The address of the stage.
startTime - The start time of the performance.
endTime - The end time of the performance.
performanceName - The name of the performance.

public record FestivalPerformanceRequest(@NotNull @NotEmpty List<FestivalArtistRequest> artists, String stageName, String stageAddress, String startTime, String endTime, String performanceName) extends Record
Represents a request to add a performance to a festival.
  • Constructor Details

    • FestivalPerformanceRequest

      public FestivalPerformanceRequest(@NotNull @NotEmpty @NotNull @NotEmpty List<FestivalArtistRequest> artists, String stageName, String stageAddress, String startTime, String endTime, String performanceName)
      Creates an instance of a FestivalPerformanceRequest record class.
      Parameters:
      artists - the value for the artists record component
      stageName - the value for the stageName record component
      stageAddress - the value for the stageAddress record component
      startTime - the value for the startTime record component
      endTime - the value for the endTime record component
      performanceName - the value for the performanceName 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.
    • artists

      @NotNull @NotEmpty public @NotNull @NotEmpty List<FestivalArtistRequest> artists()
      Returns the value of the artists record component.
      Returns:
      the value of the artists record component
    • stageName

      public String stageName()
      Returns the value of the stageName record component.
      Returns:
      the value of the stageName record component
    • stageAddress

      public String stageAddress()
      Returns the value of the stageAddress record component.
      Returns:
      the value of the stageAddress record component
    • startTime

      public String startTime()
      Returns the value of the startTime record component.
      Returns:
      the value of the startTime record component
    • endTime

      public String endTime()
      Returns the value of the endTime record component.
      Returns:
      the value of the endTime record component
    • performanceName

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