Package org.forgerock.opendj.ldap
Class DecodeException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.io.IOException
-
- org.forgerock.opendj.ldap.DecodeException
-
- All Implemented Interfaces:
Serializable,LocalizableException
public final class DecodeException extends IOException implements LocalizableException
Thrown when data from an input source cannot be decoded, perhaps due to the data being malformed in some way. By default decoding exceptions are fatal, indicating that the associated input source is no longer usable.- See Also:
- Serialized Form
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static DecodeExceptionerror(Throwable cause)Creates a new non-fatal decode exception with the provided root cause.static DecodeExceptionerror(LocalizableMessage message)Creates a new non-fatal decode exception with the provided message.static DecodeExceptionerror(LocalizableMessage message, Throwable cause)Creates a new non-fatal decode exception with the provided message and root cause.static DecodeExceptionfatalError(Throwable cause)Creates a new fatal decode exception with the provided root cause.static DecodeExceptionfatalError(LocalizableMessage message)Creates a new fatal decode exception with the provided message.static DecodeExceptionfatalError(LocalizableMessage message, Throwable cause)Creates a new fatal decode exception with the provided message and root cause.LocalizableMessagegetMessageObject()Returns the localizable message that explains the problem that occurred.booleanisFatal()Indicates whether the error was fatal and the associated input source can no longer be used.-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Method Detail
-
error
public static DecodeException error(LocalizableMessage message)
Creates a new non-fatal decode exception with the provided message.- Parameters:
message- The message that explains the problem that occurred.- Returns:
- The new non-fatal decode exception.
-
error
public static DecodeException error(Throwable cause)
Creates a new non-fatal decode exception with the provided root cause.- Parameters:
cause- The underlying cause of this exception.- Returns:
- The new non-fatal decode exception.
-
error
public static DecodeException error(LocalizableMessage message, Throwable cause)
Creates a new non-fatal decode exception with the provided message and root cause.- Parameters:
message- The message that explains the problem that occurred.cause- The underlying cause of this exception.- Returns:
- The new non-fatal decode exception.
-
fatalError
public static DecodeException fatalError(LocalizableMessage message)
Creates a new fatal decode exception with the provided message. The associated input source can no longer be used.- Parameters:
message- The message that explains the problem that occurred.- Returns:
- The new fatal decode exception.
-
fatalError
public static DecodeException fatalError(Throwable cause)
Creates a new fatal decode exception with the provided root cause. The associated input source can no longer be used.- Parameters:
cause- The underlying cause of this exception.- Returns:
- The new fatal decode exception.
-
fatalError
public static DecodeException fatalError(LocalizableMessage message, Throwable cause)
Creates a new fatal decode exception with the provided message and root cause. The associated input source can no longer be used.- Parameters:
message- The message that explains the problem that occurred.cause- The underlying cause of this exception.- Returns:
- The new fatal decode exception.
-
getMessageObject
public LocalizableMessage getMessageObject()
Description copied from interface:LocalizableExceptionReturns the localizable message that explains the problem that occurred.- Specified by:
getMessageObjectin interfaceLocalizableException- Returns:
- The localizable message that explains the problem that occurred.
-
isFatal
public boolean isFatal()
Indicates whether the error was fatal and the associated input source can no longer be used.- Returns:
trueif the error was fatal and the associated input source can no longer be used, otherwisefalse.
-
-