KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > icl > saxon > om > DocumentInfo


1 package com.icl.saxon.om;
2 import com.icl.saxon.handlers.*;
3 import com.icl.saxon.expr.*;
4 import com.icl.saxon.KeyManager;
5 import com.icl.saxon.PreparedStyleSheet;
6 import com.icl.saxon.Context;
7 import com.icl.saxon.expr.NodeSetValue;
8
9 import java.util.Hashtable JavaDoc;
10
11
12 /**
13   * The root node of an XPath tree. (Or equivalently, the tree itself).<P>
14   * This class should have been named Root; it is used not only for the root of a document,
15   * but also for the root of a result tree fragment, which is not constrained to contain a
16   * single top-level element.
17   * @author <A HREF="mailto:mhkay@iclway.co.uk>Michael H. Kay</A>
18   */

19
20 public interface DocumentInfo extends NodeInfo {
21
22     /**
23     * Set the name pool used for all names in this document
24     */

25     
26     public void setNamePool(NamePool pool);
27     
28     /**
29     * Get the name pool used for the names in this document
30     */

31     
32     public NamePool getNamePool();
33     
34     /**
35     * Get the element with a given ID, if any
36     * @param id the required ID value
37     * @return the element with the given ID, or null if there is no such ID present (or if the parser
38     * has not notified attributes as being of type ID)
39     */

40     
41     public NodeInfo selectID(String JavaDoc id);
42
43     /**
44     * Get the index for a given key
45     * @param keymanager The key manager managing this key
46     * @param fingerprint The fingerprint of the name of the key (unique with the key manager)
47     * @return The index, if one has been built, in the form of a Hashtable that
48     * maps the key value to a list of nodes having that key value. If no index
49     * has been built, returns null.
50     */

51
52     public Hashtable JavaDoc getKeyIndex(KeyManager keymanager, int fingerprint);
53
54     /**
55     * Set the index for a given key
56     * @param keymanager The key manager managing this key
57     * @param fingerprint The fingerprint of the name of the key (unique with the key manager)
58     * @param index the index, in the form of a Hashtable that
59     * maps the key value to a list of nodes having that key value
60     */

61
62     public void setKeyIndex(KeyManager keymanager, int fingerprint, Hashtable JavaDoc index);
63
64     /**
65     * Get the unparsed entity with a given name
66     * @param name the name of the entity
67     * @return the URI of the entity if there is one, or null if not
68     */

69
70     public String JavaDoc getUnparsedEntity(String JavaDoc name);
71
72     
73 }
74
75 //
76
// The contents of this file are subject to the Mozilla Public License Version 1.0 (the "License");
77
// you may not use this file except in compliance with the License. You may obtain a copy of the
78
// License at http://www.mozilla.org/MPL/
79
//
80
// Software distributed under the License is distributed on an "AS IS" basis,
81
// WITHOUT WARRANTY OF ANY KIND, either express or implied.
82
// See the License for the specific language governing rights and limitations under the License.
83
//
84
// The Original Code is: all this file.
85
//
86
// The Initial Developer of the Original Code is
87
// Michael Kay of International Computers Limited (mhkay@iclway.co.uk).
88
//
89
// Portions created by (your name) are Copyright (C) (your legal entity). All Rights Reserved.
90
//
91
// Contributor(s): none.
92
//
93
Popular Tags