home *** CD-ROM | disk | FTP | other *** search
- package com.kav.xsl;
-
- public class XSLException extends Exception {
- public static final int INVALID_CHILD_NODE = 0;
- public static final int INVALID_RULE = 1;
- public static final int INVALID_MATCH_PATTERN = 2;
- public static final int INVALID_SELECT_PATTERN = 3;
- public static final int INVALID_XSL_ELEMENT = 4;
- public static final int INVALID_ATTRIBUTE_VALUE_TEMPLATE = 5;
- public static final int MISSING_REQUIRED_ATTR = 6;
- public static String[] errorMessages = new String[]{"Invalid child node - ", "Invalid Rule - ", "Invalid Match Pattern - ", "Invalid Select Pattern - ", "Invalid XSL Element - ", "Invalid attribute value template - ", "Missing required attribute - "};
- private int error = -1;
- private static String prefix = "XSLException: ";
-
- public XSLException(String var1) {
- super(var1);
- }
-
- public XSLException(int var1, String var2) {
- super(var2);
- this.error = var1;
- }
-
- public String getMessage() {
- return this.error >= 0 && this.error < errorMessages.length ? prefix + errorMessages[this.error] + super.getMessage() : prefix + super.getMessage();
- }
- }
-