private static final String EXCEPTION_SEPARATOR = "\n---------\n";
private Throwable exception;
+ private String systemId;
+ private int line;
+ private int column;
/**
* create a new FOP Exception
super(message);
}
+ public FOPException(String message, String systemId, int line, int column) {
+ super(message);
+ this.systemId = systemId;
+ this.line = line;
+ this.column = column;
+ }
+
/**
*
* @param e Throwable object
return exception;
}
+ public void setLocation(String systemId, int line, int column) {
+ this.systemId = systemId;
+ this.line = line;
+ this.column = column;
+ }
+
+ public boolean isLocationSet() {
+ return line>=0;
+ }
+
/**
* Attempts to recast the exception as other Throwable types.
* @return the exception recast as another type if possible, otherwise null.