# Class CA1Errors

java.lang.Object
com.io7m.cardant.server.inventory.v1.internal.CA1Errors

public final class CA1Errors extends Object
Functions to transform exceptions.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `static CAHTTPResponseType`
  `errorResponseOf(CAIJ1Messages messages, CAHTTPRequestInformation information, CAIResponseBlame blame, CAException exception)`
  Transform an exception into an error response.
  `static CAHTTPResponseType`
  `errorResponseOf(CAIJ1Messages messages, CAHTTPRequestInformation information, CACommandExecutionFailure exception)`
  Transform an exception into an error response.
  `static CAHTTPResponseType`
  `transactionResponseOf(CAIJ1Messages messages, CAITransactionResponse response)`
  Produce a transaction response type.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Method Details

  - ### errorResponseOf

    public static CAHTTPResponseType errorResponseOf(CAIJ1Messages messages, CAHTTPRequestInformation information, CAIResponseBlame blame, CAException exception)
    Transform an exception into an error response.
    Parameters:
      `messages` - A message serializer
      `information` - The request information
      `blame` - The blame assignment
      `exception` - The exception
    Returns:
      An error response

  - ### errorResponseOf

    public static CAHTTPResponseType errorResponseOf(CAIJ1Messages messages, CAHTTPRequestInformation information, CACommandExecutionFailure exception)
    Transform an exception into an error response.
    Parameters:
      `messages` - A message serializer
      `information` - The request information
      `exception` - The exception
    Returns:
      An error response

  - ### transactionResponseOf

    public static CAHTTPResponseType transactionResponseOf(CAIJ1Messages messages, CAITransactionResponse response)
    Produce a transaction response type.
    Parameters:
      `messages` - A message serializer
      `response` - The transaction response
    Returns:
      An error response