Class ExceptionDescription
Most exceptions produced in a layer, has common information (layer name, driver name, error description, error code).
An ExceptionDescription can provide this extra information describing the cause of the
error, and more useful information to give to the user that works with a layer.
- Author:
- azabala
-
Constructor Summary
ConstructorsConstructorDescriptionSets the name of the layer (if a layer was using) with that this exception was produced.ExceptionDescription(int errorCode, String errorDescription) Creates a newExceptionDescriptionwith the useful values initialized. -
Method Summary
Modifier and TypeMethodDescriptionGets the name of the driver (if a driver was using) which this exception was produced.intGets the code which identifies the kind of error which is the cause of this exception.Gets the description about the error which produced this exception.abstract StringReturns a message that describes the error which produced this exception, formatted in HTML code.Gets the name of the layer (if a layer was using) with that this exception was produced.voidsetCode(int errorCode) Sets the code which identifies the kind of error which is the cause of this exception.voidsetDescription(String description) Sets the description about the error which produced this exception.voidsetDriverName(String driverName) Sets the name of the driver (if a driver was using) which this exception was produced.voidsetLayerName(String layerName) Sets the name of the layer (if a layer was using) with that this exception was produced.
-
Constructor Details
-
ExceptionDescription
public ExceptionDescription()Sets the name of the layer (if a layer was using) with that this exception was produced.
- Parameters:
layerName- the name of the layer (if a layer was using) with that this exception was produced
-
ExceptionDescription
Creates a new
ExceptionDescriptionwith the useful values initialized.- Parameters:
errorCode- code which identifies the kind of error which is the cause of this exceptionerrorDescription- description about the error which produced this exception
-
-
Method Details
-
getDriverName
Gets the name of the driver (if a driver was using) which this exception was produced.
- Returns:
- the name of the driver (if a driver was using) which this exception was produced
-
setDriverName
Sets the name of the driver (if a driver was using) which this exception was produced.
- Parameters:
driverName- the name of the driver (if a driver was using) which this exception was produced
-
getLayerName
Gets the name of the layer (if a layer was using) with that this exception was produced.
- Returns:
- the name of the layer (if a layer was using) with that this exception was produced
-
setLayerName
Sets the name of the layer (if a layer was using) with that this exception was produced.
- Parameters:
layerName- the name of the layer (if a layer was using) with that this exception was produced
-
setCode
public void setCode(int errorCode) Sets the code which identifies the kind of error which is the cause of this exception.
- Parameters:
errorCode- code which identifies the kind of error which is the cause of this exception
-
setDescription
Sets the description about the error which produced this exception.
- Parameters:
description- description about the error which produced this exception
-
getErrorCode
public int getErrorCode()Gets the code which identifies the kind of error which is the cause of this exception.
- Returns:
- code which identifies the kind of error which is the cause of this exception
-
getErrorDescription
Gets the description about the error which produced this exception.
- Returns:
- description about the error which produced this exception
-
getHtmlErrorMessage
Returns a message that describes the error which produced this exception, formatted in HTML code.
- Returns:
- message that describes the error which produced this exception, formatted in HTML code
-