org.apache.batik.bridge

Class BridgeException

public class BridgeException extends RuntimeException

Thrown when the bridge has detected an error.
Field Summary
protected Stringcode
The error code.
protected Elemente
The element on which the error occured.
protected intline
The line number on which the error occured.
protected Stringmessage
The message.
protected GraphicsNodenode
The graphics node that represents the current state of the GVT tree.
protected Object[]params
The paramters to use for the error message.
Constructor Summary
BridgeException(BridgeContext ctx, LiveAttributeException ex)
Constructs a new BridgeException based on the specified LiveAttributeException.
BridgeException(BridgeContext ctx, Element e, String code, Object[] params)
Constructs a new BridgeException with the specified parameters.
BridgeException(BridgeContext ctx, Element e, Exception ex, String code, Object[] params)
Constructs a new BridgeException with the specified parameters.
BridgeException(BridgeContext ctx, Element e, String message)
Constructs a new BridgeException with the specified parameters.
Method Summary
StringgetCode()
Returns the exception's error code
ElementgetElement()
Returns the element on which the error occurred.
GraphicsNodegetGraphicsNode()
Returns the graphics node that represents the current GVT tree built.
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

code

protected String code
The error code.

e

protected Element e
The element on which the error occured.

line

protected int line
The line number on which the error occured.

message

protected String message
The message.

node

protected GraphicsNode node
The graphics node that represents the current state of the GVT tree.

params

protected Object[] params
The paramters to use for the error message.

Constructor Detail

BridgeException

public BridgeException(BridgeContext ctx, LiveAttributeException ex)
Constructs a new BridgeException based on the specified LiveAttributeException.

Parameters: ctx the bridge context to use for determining the element's source position ex the LiveAttributeException

BridgeException

public BridgeException(BridgeContext ctx, Element e, String code, Object[] params)
Constructs a new BridgeException with the specified parameters.

Parameters: ctx the bridge context to use for determining the element's source position e the element on which the error occurred code the error code params the parameters to use for the error message

BridgeException

public BridgeException(BridgeContext ctx, Element e, Exception ex, String code, Object[] params)
Constructs a new BridgeException with the specified parameters.

Parameters: ctx the bridge context to use for determining the element's source position e the element on which the error occurred ex the exception which was the root-cause for this exception code the error code params the parameters to use for the error message

BridgeException

public BridgeException(BridgeContext ctx, Element e, String message)
Constructs a new BridgeException with the specified parameters.

Parameters: ctx the bridge context to use for determining the element's source position e the element on which the error occurred message the error message

Method Detail

getCode

public String getCode()
Returns the exception's error code

getElement

public Element getElement()
Returns the element on which the error occurred.

getGraphicsNode

public GraphicsNode getGraphicsNode()
Returns the graphics node that represents the current GVT tree built.

getMessage

public String getMessage()
Returns the error message according to the error code and parameters.

setGraphicsNode

public void setGraphicsNode(GraphicsNode node)
Sets the graphics node that represents the current GVT tree built.

Parameters: node the graphics node

Copyright B) 2008 Apache Software Foundation. All Rights Reserved.