java.lang.Object
org.openehealth.ipf.commons.ihe.xds.core.responses.Response
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
QueryResponse, RetrievedDocumentSet

public class Response extends Object implements Serializable
Basic response information.

All non-list members of this class are allowed to be null. The lists are pre-created and can therefore never be null.

Author:
Jens Riemschneider
See Also:
  • Constructor Details

    • Response

      public Response()
      Constructs the response.
    • Response

      public Response(Status status)
      Constructs the response.
      Parameters:
      status - the status of the request execution.
    • Response

      public Response(Throwable throwable, ErrorCode defaultMetaDataError, ErrorCode defaultError, String location)
      Constructs an error response object with the data from an exception.
      Parameters:
      throwable - the exception that occurred.
      defaultMetaDataError - the default error code for XDSMetaDataException.
      defaultError - the default error code for any other exception.
      location - error location.
  • Method Details

    • getStatus

      public Status getStatus()
      Returns:
      the status of the request execution.
    • setStatus

      public void setStatus(Status status)
      Parameters:
      status - the status of the request execution.
    • getErrors

      public List<ErrorInfo> getErrors()
      Returns:
      the list of errors that occurred.
    • setErrors

      public void setErrors(List<ErrorInfo> errors)
      Parameters:
      errors - the list of errors that occurred.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object