javax.jcr

## Class RepositoryException

- java.lang.Object
- - java.lang.Throwable
  - - java.lang.Exception
    - - javax.jcr.RepositoryException

All Implemented Interfaces:
  java.io.Serializable

Direct Known Subclasses:
  AccessDeniedException, ConstraintViolationException, InvalidItemStateException, InvalidQueryException, InvalidSerializedDataException, ItemExistsException, ItemNotFoundException, LockException, LoginException, MergeException, NamespaceException, NoSuchNodeTypeException, NoSuchWorkspaceException, PathNotFoundException, ReferentialIntegrityException, UnsupportedRepositoryOperationException, ValueFormatException, VersionException

    public class RepositoryException
    extends java.lang.Exception

Main exception thrown by classes in this package. May contain an error message and/or another nested exception.

See Also:
  Serialized Form

### Constructor Summary

Constructors
Constructor and Description
`RepositoryException()` Constructs a new instance of this class with `null` as its detail message.
`RepositoryException(java.lang.String message)` Constructs a new instance of this class with the specified detail message.
`RepositoryException(java.lang.String message, java.lang.Throwable rootCause)` Constructs a new instance of this class with the specified detail message and root cause.
`RepositoryException(java.lang.Throwable rootCause)` Constructs a new instance of this class with the specified root cause.

### Method Summary

All Methods Instance Methods Concrete Methods
`java.lang.Throwable` `getCause()` Returns the cause of this exception or `null` if the cause is nonexistent or unknown.
`java.lang.String` `getLocalizedMessage()` Returns the localized message, including the localized message from the nested exception if there is one.
`java.lang.String` `getMessage()` Returns the detail message, including the message from the nested exception if there is one.
`void` `printStackTrace()` Prints this `RepositoryException` and its backtrace to the standard error stream.
`void` `printStackTrace(java.io.PrintStream s)` Prints this `RepositoryException` and its backtrace to the specified print stream.
`void` `printStackTrace(java.io.PrintWriter s)` Prints this `RepositoryException` and its backtrace to the specified print writer.

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

`addSuppressed, fillInStackTrace, getStackTrace, getSuppressed, initCause, setStackTrace, toString`

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

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

### Constructor Detail

#### RepositoryException

    public RepositoryException()

Constructs a new instance of this class with `null` as its detail message.

#### RepositoryException

    public RepositoryException(java.lang.String message)

Constructs a new instance of this class with the specified detail message.

Parameters:
  `message` - the detail message. The detail message is saved for later retrieval by the `getMessage()` method.

#### RepositoryException

    public RepositoryException(java.lang.String message,
                               java.lang.Throwable rootCause)

Constructs a new instance of this class with the specified detail message and root cause.

Parameters:
  `message` - the detail message. The detail message is saved for later retrieval by the `getMessage()` method.
  `rootCause` - root failure cause

#### RepositoryException

    public RepositoryException(java.lang.Throwable rootCause)

Constructs a new instance of this class with the specified root cause.

Parameters:
  `rootCause` - root failure cause

### Method Detail

#### getMessage

    public java.lang.String getMessage()

Returns the detail message, including the message from the nested exception if there is one.

Overrides:
  `getMessage` in class `java.lang.Throwable`
Returns:
  the detail message (which may be `null`).

#### getLocalizedMessage

    public java.lang.String getLocalizedMessage()

Returns the localized message, including the localized message from the nested exception if there is one.

Overrides:
  `getLocalizedMessage` in class `java.lang.Throwable`
Returns:
  The localized description of this exception.

#### getCause

    public java.lang.Throwable getCause()

Returns the cause of this exception or `null` if the cause is nonexistent or unknown. (The cause is the throwable that caused this exception to get thrown.)

Overrides:
  `getCause` in class `java.lang.Throwable`
Returns:
  the cause of this exception or `null` if the cause is nonexistent or unknown.

#### printStackTrace

    public void printStackTrace()

Prints this `RepositoryException` and its backtrace to the standard error stream.

Overrides:
  `printStackTrace` in class `java.lang.Throwable`

#### printStackTrace

    public void printStackTrace(java.io.PrintStream s)

Prints this `RepositoryException` and its backtrace to the specified print stream.

Overrides:
  `printStackTrace` in class `java.lang.Throwable`
Parameters:
  `s` - `PrintStream` to use for output

#### printStackTrace

    public void printStackTrace(java.io.PrintWriter s)

Prints this `RepositoryException` and its backtrace to the specified print writer.

Overrides:
  `printStackTrace` in class `java.lang.Throwable`
Parameters:
  `s` - `PrintWriter` to use for output

Copyright © 2004-2005 Day Software Management AG. All Rights Reserved.