Package org.apache.batik.bridge
Class BridgeException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- org.apache.batik.bridge.BridgeException
-
- All Implemented Interfaces:
java.io.Serializable
public class BridgeException extends java.lang.RuntimeExceptionThrown when the bridge has detected an error.- Version:
- $Id: BridgeException.java 1802297 2017-07-18 13:58:12Z ssteiner $
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.StringcodeThe error code.protected org.w3c.dom.ElementeThe element on which the error occured.protected intlineThe line number on which the error occured.protected java.lang.StringmessageThe message.protected GraphicsNodenodeThe graphics node that represents the current state of the GVT tree.protected java.lang.Object[]paramsThe paramters to use for the error message.
-
Constructor Summary
Constructors Constructor Description BridgeException(BridgeContext ctx, LiveAttributeException ex)Constructs a newBridgeExceptionbased on the specifiedLiveAttributeException.BridgeException(BridgeContext ctx, org.w3c.dom.Element e, java.lang.Exception ex, java.lang.String code, java.lang.Object[] params)Constructs a newBridgeExceptionwith the specified parameters.BridgeException(BridgeContext ctx, org.w3c.dom.Element e, java.lang.String message)Constructs a newBridgeExceptionwith the specified parameters.BridgeException(BridgeContext ctx, org.w3c.dom.Element e, java.lang.String code, java.lang.Object[] params)Constructs a newBridgeExceptionwith the specified parameters.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetCode()Returns the exception's error codeorg.w3c.dom.ElementgetElement()Returns the element on which the error occurred.GraphicsNodegetGraphicsNode()Returns the graphics node that represents the current GVT tree built.java.lang.StringgetMessage()Returns the error message according to the error code and parameters.voidsetGraphicsNode(GraphicsNode node)Sets the graphics node that represents the current GVT tree built.
-
-
-
Field Detail
-
e
protected org.w3c.dom.Element e
The element on which the error occured.
-
code
protected java.lang.String code
The error code.
-
message
protected java.lang.String message
The message.
-
params
protected java.lang.Object[] params
The paramters to use for the error message.
-
line
protected int line
The line number on which the error occured.
-
node
protected GraphicsNode node
The graphics node that represents the current state of the GVT tree.
-
-
Constructor Detail
-
BridgeException
public BridgeException(BridgeContext ctx, LiveAttributeException ex)
Constructs a newBridgeExceptionbased on the specifiedLiveAttributeException.- Parameters:
ctx- the bridge context to use for determining the element's source positionex- theLiveAttributeException
-
BridgeException
public BridgeException(BridgeContext ctx, org.w3c.dom.Element e, java.lang.String code, java.lang.Object[] params)
Constructs a newBridgeExceptionwith the specified parameters.- Parameters:
ctx- the bridge context to use for determining the element's source positione- the element on which the error occurredcode- the error codeparams- the parameters to use for the error message
-
BridgeException
public BridgeException(BridgeContext ctx, org.w3c.dom.Element e, java.lang.Exception ex, java.lang.String code, java.lang.Object[] params)
Constructs a newBridgeExceptionwith the specified parameters.- Parameters:
ctx- the bridge context to use for determining the element's source positione- the element on which the error occurredex- the exception which was the root-cause for this exceptioncode- the error codeparams- the parameters to use for the error message
-
BridgeException
public BridgeException(BridgeContext ctx, org.w3c.dom.Element e, java.lang.String message)
Constructs a newBridgeExceptionwith the specified parameters.- Parameters:
ctx- the bridge context to use for determining the element's source positione- the element on which the error occurredmessage- the error message
-
-
Method Detail
-
getElement
public org.w3c.dom.Element getElement()
Returns the element on which the error occurred.
-
setGraphicsNode
public void setGraphicsNode(GraphicsNode node)
Sets the graphics node that represents the current GVT tree built.- Parameters:
node- the graphics node
-
getGraphicsNode
public GraphicsNode getGraphicsNode()
Returns the graphics node that represents the current GVT tree built.
-
getMessage
public java.lang.String getMessage()
Returns the error message according to the error code and parameters.- Overrides:
getMessagein classjava.lang.Throwable
-
getCode
public java.lang.String getCode()
Returns the exception's error code
-
-