Record Class MpicFileResponse

java.lang.Object
java.lang.Record
com.digicert.validation.mpic.api.file.MpicFileResponse

public record MpicFileResponse(PrimaryFileResponse primaryFileResponse, List<SecondaryFileResponse> secondaryFileResponses, MpicStatus mpicStatus, long numAgentCorroborations, String errorMessage) extends Record
Represents the response for a file-based MPIC (Multi-Perspective Corroboration) validation method. This record encapsulates the primary file response, a list of secondary file responses, the MPIC status, the number of agent corroborations, and any error message encountered.
  • Field Details

    • primaryFileResponse

      private final PrimaryFileResponse primaryFileResponse
      The field for the primaryFileResponse record component.
    • secondaryFileResponses

      private final List<SecondaryFileResponse> secondaryFileResponses
      The field for the secondaryFileResponses record component.
    • mpicStatus

      private final MpicStatus mpicStatus
      The field for the mpicStatus record component.
    • numAgentCorroborations

      private final long numAgentCorroborations
      The field for the numAgentCorroborations record component.
    • errorMessage

      private final String errorMessage
      The field for the errorMessage record component.
  • Constructor Details

    • MpicFileResponse

      public MpicFileResponse(PrimaryFileResponse primaryFileResponse, List<SecondaryFileResponse> secondaryFileResponses, MpicStatus mpicStatus, long numAgentCorroborations, String errorMessage)
      Creates an instance of a MpicFileResponse record class.
      Parameters:
      primaryFileResponse - the value for the primaryFileResponse record component
      secondaryFileResponses - the value for the secondaryFileResponses record component
      mpicStatus - the value for the mpicStatus record component
      numAgentCorroborations - the value for the numAgentCorroborations record component
      errorMessage - the value for the errorMessage 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. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with '=='.
      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.
    • primaryFileResponse

      public PrimaryFileResponse primaryFileResponse()
      Returns the value of the primaryFileResponse record component.
      Returns:
      the value of the primaryFileResponse record component
    • secondaryFileResponses

      public List<SecondaryFileResponse> secondaryFileResponses()
      Returns the value of the secondaryFileResponses record component.
      Returns:
      the value of the secondaryFileResponses record component
    • mpicStatus

      public MpicStatus mpicStatus()
      Returns the value of the mpicStatus record component.
      Returns:
      the value of the mpicStatus record component
    • numAgentCorroborations

      public long numAgentCorroborations()
      Returns the value of the numAgentCorroborations record component.
      Returns:
      the value of the numAgentCorroborations record component
    • errorMessage

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