wjhk.jupload2.exception
Class JUploadException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by wjhk.jupload2.exception.JUploadException
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
JUploadExceptionStopAddingFiles, JUploadExceptionTooBigFile, JUploadExceptionUploadFailed, JUploadIOException

public class JUploadException
extends Exception

A new kind of exceptions. Currently : no other specialization than its name.

Version:
$Revision: 887 $
Author:
etienne_sf
See Also:
Serialized Form

Constructor Summary
JUploadException(Exception ex)
          Creates a new instance with a specified original exception.
JUploadException(String message)
          Creates a new instance with a specified message.
JUploadException(String message, Throwable ex)
          Creates a new instance with a specified message and original exception.
 
Method Summary
 String getClassNameAndClause()
          Returns JUploadExceptionClassName:CauseClassName.
 String getLocation()
          Retrieves the human readable location of this exception (Class.method, filename, linenumber)
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

JUploadException

public JUploadException(String message)
Creates a new instance with a specified message.

Parameters:
message - The message to be associated with this instance.

JUploadException

public JUploadException(Exception ex)
Creates a new instance with a specified original exception.

Parameters:
ex - The exception that was originally thrown.

JUploadException

public JUploadException(String message,
                        Throwable ex)
Creates a new instance with a specified message and original exception.

Parameters:
message - The message to be associated with this instance.
ex - The exception that was originally thrown.
Method Detail

getLocation

public String getLocation()
Retrieves the human readable location of this exception (Class.method, filename, linenumber)

Returns:
The location where this exception was thrown.

getClassNameAndClause

public String getClassNameAndClause()
Returns JUploadExceptionClassName:CauseClassName. For instance:
wjhk.jupload2.exception.JUploadIOException:FileNotFoundException
or
wjhk.jupload2.exception.JUploadIOException (if there is no cause given to the JUploadException constructor).

Returns:
The class name(s) that can be displayed in an error message.