01: package net.sf.saxon.tree;
02:
03: import net.sf.saxon.event.LocationProvider;
04: import net.sf.saxon.om.AttributeCollectionImpl;
05: import net.sf.saxon.om.NodeInfo;
06:
07: /**
08: * Interface NodeFactory. <br>
09: * A Factory for nodes used to build a tree. <br>
10: * Currently only allows Element nodes to be user-constructed.
11: * @author Michael H. Kay
12: * @version 25 February 2000
13: */
14:
15: public interface NodeFactory {
16:
17: /**
18: * Create an Element node
19: * @param parent The parent element
20: * @param nameCode The element name
21: * @param attlist The attribute collection, excluding any namespace attributes
22: * @param namespaces List of new namespace declarations for this element, as a sequence
23: * of namespace codes representing pairs of strings: (prefix1, uri1), (prefix2, uri2)...
24: * @param namespacesUsed the number of elemnts of the namespaces array actually used
25: * @param locator Indicates the source document and line number containing the node
26: * @param locationId Indicates the source document and line number containing the node
27: * @param sequenceNumber Sequence number to be assigned to represent document order.
28: */
29:
30: public ElementImpl makeElementNode(NodeInfo parent, int nameCode,
31: AttributeCollectionImpl attlist, int[] namespaces,
32: int namespacesUsed, LocationProvider locator,
33: int locationId, int sequenceNumber);
34:
35: }
36:
37: //
38: // The contents of this file are subject to the Mozilla Public License Version 1.0 (the "License");
39: // you may not use this file except in compliance with the License. You may obtain a copy of the
40: // License at http://www.mozilla.org/MPL/
41: //
42: // Software distributed under the License is distributed on an "AS IS" basis,
43: // WITHOUT WARRANTY OF ANY KIND, either express or implied.
44: // See the License for the specific language governing rights and limitations under the License.
45: //
46: // The Original Code is: all this file.
47: //
48: // The Initial Developer of the Original Code is Michael H. Kay.
49: //
50: // Portions created by (your name) are Copyright (C) (your legal entity). All Rights Reserved.
51: //
52: // Contributor(s): none.
53: //
|