OSDN Git Service

2013.10.24
[uclinux-h8/uClinux-dist.git] / lib / classpath / external / w3c_dom / org / w3c / dom / xpath / XPathException.java
1 /*
2  * Copyright (c) 2004 World Wide Web Consortium,
3  *
4  * (Massachusetts Institute of Technology, European Research Consortium for
5  * Informatics and Mathematics, Keio University). All Rights Reserved. This
6  * work is distributed under the W3C(r) Software License [1] in the hope that
7  * it will be useful, but WITHOUT ANY WARRANTY; without even the implied
8  * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
9  *
10  * [1] http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
11  */
12
13 package org.w3c.dom.xpath;
14
15 /**
16  * A new exception has been created for exceptions specific to these XPath 
17  * interfaces.
18  * <p>See also the <a href='http://www.w3.org/TR/2004/NOTE-DOM-Level-3-XPath-20040226'>Document Object Model (DOM) Level 3 XPath Specification</a>.
19  */
20 public class XPathException extends RuntimeException {
21     public XPathException(short code, String message) {
22        super(message);
23        this.code = code;
24     }
25     public short   code;
26     // XPathExceptionCode
27     /**
28      * If the expression has a syntax error or otherwise is not a legal 
29      * expression according to the rules of the specific 
30      * <code>XPathEvaluator</code> or contains specialized extension 
31      * functions or variables not supported by this implementation.
32      */
33     public static final short INVALID_EXPRESSION_ERR    = 51;
34     /**
35      * If the expression cannot be converted to return the specified type.
36      */
37     public static final short TYPE_ERR                  = 52;
38
39 }