Package org.dspace.content.packager
Class PackageException
java.lang.Object
java.lang.Throwable
java.lang.Exception
org.dspace.content.packager.PackageException
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
PackageValidationException
This is a superclass for exceptions representing a failure when
importing or exporting a package. E.g., unacceptable package format
or contents. Implementations should throw one of the more specific
exceptions. This class is intended for declarations and catch clauses.
- Author:
- Larry Stone
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionCreate a new exception with no message.PackageException(String message) Create a new exception with the given message.PackageException(String message, Throwable cause) Create a new exception wrapping it around another exception.PackageException(Throwable cause) Create a new exception wrapping the given underlying cause. -
Method Summary
Modifier and TypeMethodDescriptionvoidlog(org.apache.logging.log4j.Logger log) Write details of this exception to the indicated logger.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
PackageException
public PackageException()Create a new exception with no message. -
PackageException
Create a new exception with the given message.- Parameters:
message- - message text.
-
PackageException
Create a new exception wrapping the given underlying cause.- Parameters:
cause- - exception specifying the cause of this failure.
-
PackageException
Create a new exception wrapping it around another exception.- Parameters:
message- - message text.cause- - exception specifying the cause of this failure.
-
-
Method Details
-
log
public void log(org.apache.logging.log4j.Logger log) Write details of this exception to the indicated logger. Dump a stack trace to the log to aid in debugging.- Parameters:
log- logger
-