public class JcrDavException extends DavException
JcrDavException
extends the DavException
in order to
wrap various repository exceptions.XML_ERROR
Constructor and Description |
---|
JcrDavException(RepositoryException cause)
Same as
JcrDavException(Throwable, int) where the
error code is retrieved from an internal mapping. |
JcrDavException(Throwable cause,
int errorCode)
Create a new
JcrDavException . |
Modifier and Type | Method and Description |
---|---|
boolean |
hasErrorCondition()
Always returns true.
|
Element |
toXml(Document document)
Returns a DAV:error Xml element containing the exceptions class and the
message as child elements.
|
getErrorCode, getErrorCondition, getStatusPhrase, getStatusPhrase
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
public JcrDavException(Throwable cause, int errorCode)
JcrDavException
.cause
- The original cause of this DavException
. Note, that
in contrast to Throwable.Throwable(Throwable)
, Throwable.Throwable(String, Throwable)
and
Throwable.initCause(Throwable)
the cause must not be null
.errorCode
- Status code for the response.NullPointerException
- if the given exception is null
.DavException.DavException(int, String)
,
DavException.DavException(int)
public JcrDavException(RepositoryException cause)
JcrDavException(Throwable, int)
where the
error code is retrieved from an internal mapping.cause
- Cause of this DavExceptionNullPointerException
- if the given exception is null
.JcrDavException(Throwable, int)
public boolean hasErrorCondition()
hasErrorCondition
in class DavException
public Element toXml(Document document)
toXml
in interface XmlSerializable
toXml
in class DavException
document
- XmlSerializable.toXml(Document)
Copyright © 2004–2024 The Apache Software Foundation. All rights reserved.