Package com.tietoenator.trip.jxp

# Class TdbException

java.lang.Object
java.lang.Throwable
java.lang.Exception
com.tietoenator.trip.jxp.TdbException

All Implemented Interfaces:
  `Serializable`

public class TdbException extends Exception
All exceptions thrown by this class library conform to this type. An exception may well have one or more other exceptions contained within it.

See Also:
  - Serialized Form

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final int`
  `COMMUNICATIONS_ERROR`
  Communications failure talking to the server
  `static final int`
  `END_OF_DATA`
  When iterating through a collection, the end of the collection has been reached.
  `static final int`
  `GENERAL_ERROR`
  Unspecified error in operation.
  `static final int`
  `INVALID_ARGS`
  Programmer error, invalid arguments provided to a method call.
  `static final int`
  `NO_LICENSE`
  TRIPjxp is not licensed for use.
  `static final int`
  `NOT_LOGGED_IN`
  No user has logged in to the session yet.
  `static final int`
  `NOT_SUPPORTED`
  The method or property is not supported for the class on which it was invoked.
  `static final int`
  `PARSER_ERROR`
  XML structure error
  `static final int`
  `TIMEOUT`
  The functionality or data being accessed is no longer available due to timeout.
  `static final int`
  `TRANSACTION_CANCELLED`
  Xml transaction was cancelled.
  `static final int`
  `UNEXPECTED_RESPONSE`
  The server sent back an XML response of an unexpected type
  `static final int`
  `UNEXPECTED_STATE`
  The system is in an unexpected state, potentially due to an error in the server
  `static final int`
  `UNUSABLE_SESSION`
  Attempt to use an object with a session of an incompatible type, for example attempting to use grid objects on a TRIPnet connection
  `static final int`
  `VALIDATION_ERROR`
  Provided data could not be validated.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `TdbException(int code)`
  Constructor
  `TdbException(int code, String msg)`
  Constructor
  `TdbException(int code, Throwable cause)`
  Constructor
  `TdbException(int code, Throwable cause, String arg)`
  Constructor
  `TdbException(int code, Throwable cause, String msg, String logexcerpt)`
  Constructor
  `TdbException(String msg)`
  Constructor
  `TdbException(String msg, Throwable cause)`
  Constructor

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `getCode()`
  Retrieve the error code from the exception
  `String`
  `getDebugMessage()`
  Retrieve a fully decorated error string; this contains the call stack and all embedded exceptions (and their call stacks).
  `String`
  `getLogExcerpt()`
  TRIPsystem API log excerpt related to the thrown exception.
  `String`
  `getMessage()`
  Default message preparation
  `String`
  `getSimpleMessage()`
  Retrieve an undecorated error string, i.e.

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

  `addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString`

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

  `equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- ## Field Details

  - ### UNEXPECTED_STATE

    public static final int UNEXPECTED_STATE
    The system is in an unexpected state, potentially due to an error in the server
    See Also:
      - Constant Field Values

  - ### COMMUNICATIONS_ERROR

    public static final int COMMUNICATIONS_ERROR
    Communications failure talking to the server
    See Also:
      - Constant Field Values

  - ### UNEXPECTED_RESPONSE

    public static final int UNEXPECTED_RESPONSE
    The server sent back an XML response of an unexpected type
    See Also:
      - Constant Field Values

  - ### PARSER_ERROR

    public static final int PARSER_ERROR
    XML structure error
    See Also:
      - Constant Field Values

  - ### UNUSABLE_SESSION

    public static final int UNUSABLE_SESSION
    Attempt to use an object with a session of an incompatible type, for example attempting to use grid objects on a TRIPnet connection
    See Also:
      - Constant Field Values

  - ### INVALID_ARGS

    public static final int INVALID_ARGS
    Programmer error, invalid arguments provided to a method call.
    See Also:
      - Constant Field Values

  - ### END_OF_DATA

    public static final int END_OF_DATA
    When iterating through a collection, the end of the collection has been reached.
    See Also:
      - Constant Field Values

  - ### VALIDATION_ERROR

    public static final int VALIDATION_ERROR
    Provided data could not be validated.
    See Also:
      - Constant Field Values

  - ### NO_LICENSE

    public static final int NO_LICENSE
    TRIPjxp is not licensed for use.
    See Also:
      - Constant Field Values

  - ### NOT_SUPPORTED

    public static final int NOT_SUPPORTED
    The method or property is not supported for the class on which it was invoked.
    See Also:
      - Constant Field Values

  - ### TIMEOUT

    public static final int TIMEOUT
    The functionality or data being accessed is no longer available due to timeout.
    See Also:
      - Constant Field Values

  - ### NOT_LOGGED_IN

    public static final int NOT_LOGGED_IN
    No user has logged in to the session yet.
    See Also:
      - Constant Field Values

  - ### TRANSACTION_CANCELLED

    public static final int TRANSACTION_CANCELLED
    Xml transaction was cancelled.
    See Also:
      - Constant Field Values

  - ### GENERAL_ERROR

    public static final int GENERAL_ERROR
    Unspecified error in operation.
    See Also:
      - Constant Field Values

- ## Constructor Details

  - ### TdbException

    public TdbException(int code)
    Constructor
    Parameters:
      `code` - Error code

  - ### TdbException

    public TdbException(int code, Throwable cause)
    Constructor
    Parameters:
      `code` - Error code
      `cause` - Embedded exception, i.e. the exception that caused this TdbException to be thrown

  - ### TdbException

    public TdbException(int code, Throwable cause, String arg)
    Constructor
    Parameters:
      `code` - Error code
      `cause` - Embedded exception, i.e. the exception that caused this TdbException to be thrown
      `arg` - Optional argument, e.g. location data

  - ### TdbException

    public TdbException(int code, Throwable cause, String msg, String logexcerpt)
    Constructor
    Parameters:
      `code` - Error code
      `cause` - Embedded exception, i.e. the exception that caused this TdbException to be thrown
      `msg` - Message to accompany error, typically TRIP-generated
      `logexcerpt` - API log excerpt from TRIPsystem related to the thrown exception

  - ### TdbException

    public TdbException(int code, String msg)
    Constructor
    Parameters:
      `code` - Error code
      `msg` - Message to accompany error, typically TRIP-generated

  - ### TdbException

    public TdbException(String msg)
    Constructor
    Parameters:
      `msg` - Error message

  - ### TdbException

    public TdbException(String msg, Throwable cause)
    Constructor
    Parameters:
      `msg` - Error message
      `cause` - Embedded exception, i.e. the exception that caused this TdbException to be thrown

- ## Method Details

  - ### getCode

    public int getCode()
    Retrieve the error code from the exception
    Returns:
      The error code

  - ### getSimpleMessage

    public String getSimpleMessage()
    Retrieve an undecorated error string, i.e. no call stacks.
    Returns:
      The undecorated error string.

  - ### getDebugMessage

    public String getDebugMessage()
    Retrieve a fully decorated error string; this contains the call stack and all embedded exceptions (and their call stacks). This is useful for producing a string for transmission to clients in a single call.
    Returns:
      The fully decorated error string

  - ### getMessage

    public String getMessage()
    Default message preparation
    Overrides:
      `getMessage` in class `Throwable`
    Returns:
      An undecorated error string

  - ### getLogExcerpt

    public String getLogExcerpt()
    TRIPsystem API log excerpt related to the thrown exception.

    If session-specific server-side API logging is enabled this property will contain an excerpt from the TRIPsystem API for the associated TRIPjxp call.

    Returns:
      API log excerpt, or an empty string if none is available.