jaxp/src/com/sun/org/apache/xml/internal/dtm/DTM.java
author lana
Tue, 18 Mar 2014 17:49:48 -0700
changeset 23377 2af1ddf102a4
parent 12457 c348e06f0e82
permissions -rw-r--r--
Merge
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
6
7f561c08de6b Initial load
duke
parents:
diff changeset
     1
/*
7f561c08de6b Initial load
duke
parents:
diff changeset
     2
 * reserved comment block
7f561c08de6b Initial load
duke
parents:
diff changeset
     3
 * DO NOT REMOVE OR ALTER!
7f561c08de6b Initial load
duke
parents:
diff changeset
     4
 */
7f561c08de6b Initial load
duke
parents:
diff changeset
     5
/*
7f561c08de6b Initial load
duke
parents:
diff changeset
     6
 * Copyright 1999-2004 The Apache Software Foundation.
7f561c08de6b Initial load
duke
parents:
diff changeset
     7
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
     8
 * Licensed under the Apache License, Version 2.0 (the "License");
7f561c08de6b Initial load
duke
parents:
diff changeset
     9
 * you may not use this file except in compliance with the License.
7f561c08de6b Initial load
duke
parents:
diff changeset
    10
 * You may obtain a copy of the License at
7f561c08de6b Initial load
duke
parents:
diff changeset
    11
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    12
 *     http://www.apache.org/licenses/LICENSE-2.0
7f561c08de6b Initial load
duke
parents:
diff changeset
    13
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    14
 * Unless required by applicable law or agreed to in writing, software
7f561c08de6b Initial load
duke
parents:
diff changeset
    15
 * distributed under the License is distributed on an "AS IS" BASIS,
7f561c08de6b Initial load
duke
parents:
diff changeset
    16
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
7f561c08de6b Initial load
duke
parents:
diff changeset
    17
 * See the License for the specific language governing permissions and
7f561c08de6b Initial load
duke
parents:
diff changeset
    18
 * limitations under the License.
7f561c08de6b Initial load
duke
parents:
diff changeset
    19
 */
7f561c08de6b Initial load
duke
parents:
diff changeset
    20
/*
7f561c08de6b Initial load
duke
parents:
diff changeset
    21
 * $Id: DTM.java,v 1.2.4.1 2005/09/15 08:14:51 suresh_emailid Exp $
7f561c08de6b Initial load
duke
parents:
diff changeset
    22
 */
7f561c08de6b Initial load
duke
parents:
diff changeset
    23
package com.sun.org.apache.xml.internal.dtm;
7f561c08de6b Initial load
duke
parents:
diff changeset
    24
7f561c08de6b Initial load
duke
parents:
diff changeset
    25
import javax.xml.transform.SourceLocator;
7f561c08de6b Initial load
duke
parents:
diff changeset
    26
7f561c08de6b Initial load
duke
parents:
diff changeset
    27
import com.sun.org.apache.xml.internal.utils.XMLString;
7f561c08de6b Initial load
duke
parents:
diff changeset
    28
7f561c08de6b Initial load
duke
parents:
diff changeset
    29
/**
7f561c08de6b Initial load
duke
parents:
diff changeset
    30
 * <code>DTM</code> is an XML document model expressed as a table
7f561c08de6b Initial load
duke
parents:
diff changeset
    31
 * rather than an object tree. It attempts to provide an interface to
7f561c08de6b Initial load
duke
parents:
diff changeset
    32
 * a parse tree that has very little object creation. (DTM
7f561c08de6b Initial load
duke
parents:
diff changeset
    33
 * implementations may also support incremental construction of the
7f561c08de6b Initial load
duke
parents:
diff changeset
    34
 * model, but that's hidden from the DTM API.)
7f561c08de6b Initial load
duke
parents:
diff changeset
    35
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    36
 * <p>Nodes in the DTM are identified by integer "handles".  A handle must
7f561c08de6b Initial load
duke
parents:
diff changeset
    37
 * be unique within a process, and carries both node identification and
7f561c08de6b Initial load
duke
parents:
diff changeset
    38
 * document identification.  It must be possible to compare two handles
7f561c08de6b Initial load
duke
parents:
diff changeset
    39
 * (and thus their nodes) for identity with "==".</p>
7f561c08de6b Initial load
duke
parents:
diff changeset
    40
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    41
 * <p>Namespace URLs, local-names, and expanded-names can all be
7f561c08de6b Initial load
duke
parents:
diff changeset
    42
 * represented by and tested as integer ID values.  An expanded name
7f561c08de6b Initial load
duke
parents:
diff changeset
    43
 * represents (and may or may not directly contain) a combination of
7f561c08de6b Initial load
duke
parents:
diff changeset
    44
 * the URL ID, and the local-name ID.  Note that the namespace URL id
7f561c08de6b Initial load
duke
parents:
diff changeset
    45
 * can be 0, which should have the meaning that the namespace is null.
7f561c08de6b Initial load
duke
parents:
diff changeset
    46
 * For consistancy, zero should not be used for a local-name index. </p>
7f561c08de6b Initial load
duke
parents:
diff changeset
    47
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    48
 * <p>Text content of a node is represented by an index and length,
7f561c08de6b Initial load
duke
parents:
diff changeset
    49
 * permitting efficient storage such as a shared FastStringBuffer.</p>
7f561c08de6b Initial load
duke
parents:
diff changeset
    50
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    51
 * <p>The model of the tree, as well as the general navigation model,
7f561c08de6b Initial load
duke
parents:
diff changeset
    52
 * is that of XPath 1.0, for the moment.  The model will eventually be
7f561c08de6b Initial load
duke
parents:
diff changeset
    53
 * adapted to match the XPath 2.0 data model, XML Schema, and
7f561c08de6b Initial load
duke
parents:
diff changeset
    54
 * InfoSet.</p>
7f561c08de6b Initial load
duke
parents:
diff changeset
    55
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    56
 * <p>DTM does _not_ directly support the W3C's Document Object
7f561c08de6b Initial load
duke
parents:
diff changeset
    57
 * Model. However, it attempts to come close enough that an
7f561c08de6b Initial load
duke
parents:
diff changeset
    58
 * implementation of DTM can be created that wraps a DOM and vice
7f561c08de6b Initial load
duke
parents:
diff changeset
    59
 * versa.</p>
7f561c08de6b Initial load
duke
parents:
diff changeset
    60
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    61
 * <p><strong>Please Note:</strong> The DTM API is still
7f561c08de6b Initial load
duke
parents:
diff changeset
    62
 * <strong>Subject To Change.</strong> This wouldn't affect most
7f561c08de6b Initial load
duke
parents:
diff changeset
    63
 * users, but might require updating some extensions.</p>
7f561c08de6b Initial load
duke
parents:
diff changeset
    64
 *
7f561c08de6b Initial load
duke
parents:
diff changeset
    65
 * <p> The largest change being contemplated is a reconsideration of
7f561c08de6b Initial load
duke
parents:
diff changeset
    66
 * the Node Handle representation.  We are still not entirely sure
7f561c08de6b Initial load
duke
parents:
diff changeset
    67
 * that an integer packed with two numeric subfields is really the
7f561c08de6b Initial load
duke
parents:
diff changeset
    68
 * best solution. It has been suggested that we move up to a Long, to
7f561c08de6b Initial load
duke
parents:
diff changeset
    69
 * permit more nodes per document without having to reduce the number
7f561c08de6b Initial load
duke
parents:
diff changeset
    70
 * of slots in the DTMManager. There's even been a proposal that we
7f561c08de6b Initial load
duke
parents:
diff changeset
    71
 * replace these integers with "cursor" objects containing the
7f561c08de6b Initial load
duke
parents:
diff changeset
    72
 * internal node id and a pointer to the actual DTM object; this might
7f561c08de6b Initial load
duke
parents:
diff changeset
    73
 * reduce the need to continuously consult the DTMManager to retrieve
7f561c08de6b Initial load
duke
parents:
diff changeset
    74
 * the latter, and might provide a useful "hook" back into normal Java
7f561c08de6b Initial load
duke
parents:
diff changeset
    75
 * heap management.  But changing this datatype would have huge impact
7f561c08de6b Initial load
duke
parents:
diff changeset
    76
 * on Xalan's internals -- especially given Java's lack of C-style
7f561c08de6b Initial load
duke
parents:
diff changeset
    77
 * typedefs -- so we won't cut over unless we're convinced the new
7f561c08de6b Initial load
duke
parents:
diff changeset
    78
 * solution really would be an improvement!</p>
7f561c08de6b Initial load
duke
parents:
diff changeset
    79
 * */
7f561c08de6b Initial load
duke
parents:
diff changeset
    80
public interface DTM
7f561c08de6b Initial load
duke
parents:
diff changeset
    81
{
7f561c08de6b Initial load
duke
parents:
diff changeset
    82
7f561c08de6b Initial load
duke
parents:
diff changeset
    83
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
    84
   * Null node handles are represented by this value.
7f561c08de6b Initial load
duke
parents:
diff changeset
    85
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
    86
  public static final int NULL = -1;
7f561c08de6b Initial load
duke
parents:
diff changeset
    87
7f561c08de6b Initial load
duke
parents:
diff changeset
    88
  // These nodeType mnemonics and values are deliberately the same as those
7f561c08de6b Initial load
duke
parents:
diff changeset
    89
  // used by the DOM, for convenient mapping
7f561c08de6b Initial load
duke
parents:
diff changeset
    90
  //
7f561c08de6b Initial load
duke
parents:
diff changeset
    91
  // %REVIEW% Should we actually define these as initialized to,
7f561c08de6b Initial load
duke
parents:
diff changeset
    92
  // eg. org.w3c.dom.Document.ELEMENT_NODE?
7f561c08de6b Initial load
duke
parents:
diff changeset
    93
7f561c08de6b Initial load
duke
parents:
diff changeset
    94
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
    95
   * The node is a <code>Root</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
    96
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
    97
  public static final short ROOT_NODE = 0;
7f561c08de6b Initial load
duke
parents:
diff changeset
    98
7f561c08de6b Initial load
duke
parents:
diff changeset
    99
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   100
   * The node is an <code>Element</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   101
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   102
  public static final short ELEMENT_NODE = 1;
7f561c08de6b Initial load
duke
parents:
diff changeset
   103
7f561c08de6b Initial load
duke
parents:
diff changeset
   104
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   105
   * The node is an <code>Attr</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   106
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   107
  public static final short ATTRIBUTE_NODE = 2;
7f561c08de6b Initial load
duke
parents:
diff changeset
   108
7f561c08de6b Initial load
duke
parents:
diff changeset
   109
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   110
   * The node is a <code>Text</code> node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   111
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   112
  public static final short TEXT_NODE = 3;
7f561c08de6b Initial load
duke
parents:
diff changeset
   113
7f561c08de6b Initial load
duke
parents:
diff changeset
   114
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   115
   * The node is a <code>CDATASection</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   116
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   117
  public static final short CDATA_SECTION_NODE = 4;
7f561c08de6b Initial load
duke
parents:
diff changeset
   118
7f561c08de6b Initial load
duke
parents:
diff changeset
   119
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   120
   * The node is an <code>EntityReference</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   121
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   122
  public static final short ENTITY_REFERENCE_NODE = 5;
7f561c08de6b Initial load
duke
parents:
diff changeset
   123
7f561c08de6b Initial load
duke
parents:
diff changeset
   124
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   125
   * The node is an <code>Entity</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   126
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   127
  public static final short ENTITY_NODE = 6;
7f561c08de6b Initial load
duke
parents:
diff changeset
   128
7f561c08de6b Initial load
duke
parents:
diff changeset
   129
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   130
   * The node is a <code>ProcessingInstruction</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   131
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   132
  public static final short PROCESSING_INSTRUCTION_NODE = 7;
7f561c08de6b Initial load
duke
parents:
diff changeset
   133
7f561c08de6b Initial load
duke
parents:
diff changeset
   134
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   135
   * The node is a <code>Comment</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   136
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   137
  public static final short COMMENT_NODE = 8;
7f561c08de6b Initial load
duke
parents:
diff changeset
   138
7f561c08de6b Initial load
duke
parents:
diff changeset
   139
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   140
   * The node is a <code>Document</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   141
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   142
  public static final short DOCUMENT_NODE = 9;
7f561c08de6b Initial load
duke
parents:
diff changeset
   143
7f561c08de6b Initial load
duke
parents:
diff changeset
   144
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   145
   * The node is a <code>DocumentType</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   146
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   147
  public static final short DOCUMENT_TYPE_NODE = 10;
7f561c08de6b Initial load
duke
parents:
diff changeset
   148
7f561c08de6b Initial load
duke
parents:
diff changeset
   149
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   150
   * The node is a <code>DocumentFragment</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   151
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   152
  public static final short DOCUMENT_FRAGMENT_NODE = 11;
7f561c08de6b Initial load
duke
parents:
diff changeset
   153
7f561c08de6b Initial load
duke
parents:
diff changeset
   154
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   155
   * The node is a <code>Notation</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   156
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   157
  public static final short NOTATION_NODE = 12;
7f561c08de6b Initial load
duke
parents:
diff changeset
   158
7f561c08de6b Initial load
duke
parents:
diff changeset
   159
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   160
   * The node is a <code>namespace node</code>. Note that this is not
7f561c08de6b Initial load
duke
parents:
diff changeset
   161
   * currently a node type defined by the DOM API.
7f561c08de6b Initial load
duke
parents:
diff changeset
   162
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   163
  public static final short NAMESPACE_NODE = 13;
7f561c08de6b Initial load
duke
parents:
diff changeset
   164
7f561c08de6b Initial load
duke
parents:
diff changeset
   165
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   166
   * The number of valid nodetypes.
7f561c08de6b Initial load
duke
parents:
diff changeset
   167
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   168
  public static final short  NTYPES = 14;
7f561c08de6b Initial load
duke
parents:
diff changeset
   169
7f561c08de6b Initial load
duke
parents:
diff changeset
   170
  // ========= DTM Implementation Control Functions. ==============
7f561c08de6b Initial load
duke
parents:
diff changeset
   171
  // %TBD% RETIRED -- do via setFeature if needed. Remove from impls.
7f561c08de6b Initial load
duke
parents:
diff changeset
   172
  // public void setParseBlockSize(int blockSizeSuggestion);
7f561c08de6b Initial load
duke
parents:
diff changeset
   173
7f561c08de6b Initial load
duke
parents:
diff changeset
   174
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   175
   * Set an implementation dependent feature.
7f561c08de6b Initial load
duke
parents:
diff changeset
   176
   * <p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   177
   * %REVIEW% Do we really expect to set features on DTMs?
7f561c08de6b Initial load
duke
parents:
diff changeset
   178
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   179
   * @param featureId A feature URL.
7f561c08de6b Initial load
duke
parents:
diff changeset
   180
   * @param state true if this feature should be on, false otherwise.
7f561c08de6b Initial load
duke
parents:
diff changeset
   181
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   182
  public void setFeature(String featureId, boolean state);
7f561c08de6b Initial load
duke
parents:
diff changeset
   183
7f561c08de6b Initial load
duke
parents:
diff changeset
   184
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   185
   * Set a run time property for this DTM instance.
7f561c08de6b Initial load
duke
parents:
diff changeset
   186
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   187
   * @param property a <code>String</code> value
7f561c08de6b Initial load
duke
parents:
diff changeset
   188
   * @param value an <code>Object</code> value
7f561c08de6b Initial load
duke
parents:
diff changeset
   189
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   190
  public void setProperty(String property, Object value);
7f561c08de6b Initial load
duke
parents:
diff changeset
   191
7f561c08de6b Initial load
duke
parents:
diff changeset
   192
  // ========= Document Navigation Functions =========
7f561c08de6b Initial load
duke
parents:
diff changeset
   193
7f561c08de6b Initial load
duke
parents:
diff changeset
   194
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   195
   * This returns a stateless "traverser", that can navigate over an
7f561c08de6b Initial load
duke
parents:
diff changeset
   196
   * XPath axis, though not in document order.
7f561c08de6b Initial load
duke
parents:
diff changeset
   197
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   198
   * @param axis One of Axes.ANCESTORORSELF, etc.
7f561c08de6b Initial load
duke
parents:
diff changeset
   199
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   200
   * @return A DTMAxisIterator, or null if the givin axis isn't supported.
7f561c08de6b Initial load
duke
parents:
diff changeset
   201
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   202
  public DTMAxisTraverser getAxisTraverser(final int axis);
7f561c08de6b Initial load
duke
parents:
diff changeset
   203
7f561c08de6b Initial load
duke
parents:
diff changeset
   204
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   205
   * This is a shortcut to the iterators that implement
7f561c08de6b Initial load
duke
parents:
diff changeset
   206
   * XPath axes.
7f561c08de6b Initial load
duke
parents:
diff changeset
   207
   * Returns a bare-bones iterator that must be initialized
7f561c08de6b Initial load
duke
parents:
diff changeset
   208
   * with a start node (using iterator.setStartNode()).
7f561c08de6b Initial load
duke
parents:
diff changeset
   209
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   210
   * @param axis One of Axes.ANCESTORORSELF, etc.
7f561c08de6b Initial load
duke
parents:
diff changeset
   211
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   212
   * @return A DTMAxisIterator, or null if the givin axis isn't supported.
7f561c08de6b Initial load
duke
parents:
diff changeset
   213
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   214
  public DTMAxisIterator getAxisIterator(final int axis);
7f561c08de6b Initial load
duke
parents:
diff changeset
   215
7f561c08de6b Initial load
duke
parents:
diff changeset
   216
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   217
   * Get an iterator that can navigate over an XPath Axis, predicated by
7f561c08de6b Initial load
duke
parents:
diff changeset
   218
   * the extended type ID.
7f561c08de6b Initial load
duke
parents:
diff changeset
   219
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   220
   * @param axis
7f561c08de6b Initial load
duke
parents:
diff changeset
   221
   * @param type An extended type ID.
7f561c08de6b Initial load
duke
parents:
diff changeset
   222
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   223
   * @return A DTMAxisIterator, or null if the givin axis isn't supported.
7f561c08de6b Initial load
duke
parents:
diff changeset
   224
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   225
  public DTMAxisIterator getTypedAxisIterator(final int axis, final int type);
7f561c08de6b Initial load
duke
parents:
diff changeset
   226
7f561c08de6b Initial load
duke
parents:
diff changeset
   227
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   228
   * Given a node handle, test if it has child nodes.
7f561c08de6b Initial load
duke
parents:
diff changeset
   229
   * <p> %REVIEW% This is obviously useful at the DOM layer, where it
7f561c08de6b Initial load
duke
parents:
diff changeset
   230
   * would permit testing this without having to create a proxy
7f561c08de6b Initial load
duke
parents:
diff changeset
   231
   * node. It's less useful in the DTM API, where
7f561c08de6b Initial load
duke
parents:
diff changeset
   232
   * (dtm.getFirstChild(nodeHandle)!=DTM.NULL) is just as fast and
7f561c08de6b Initial load
duke
parents:
diff changeset
   233
   * almost as self-evident. But it's a convenience, and eases porting
7f561c08de6b Initial load
duke
parents:
diff changeset
   234
   * of DOM code to DTM.  </p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   235
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   236
   * @param nodeHandle int Handle of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   237
   * @return int true if the given node has child nodes.
7f561c08de6b Initial load
duke
parents:
diff changeset
   238
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   239
  public boolean hasChildNodes(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   240
7f561c08de6b Initial load
duke
parents:
diff changeset
   241
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   242
   * Given a node handle, get the handle of the node's first child.
7f561c08de6b Initial load
duke
parents:
diff changeset
   243
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   244
   * @param nodeHandle int Handle of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   245
   * @return int DTM node-number of first child,
7f561c08de6b Initial load
duke
parents:
diff changeset
   246
   * or DTM.NULL to indicate none exists.
7f561c08de6b Initial load
duke
parents:
diff changeset
   247
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   248
  public int getFirstChild(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   249
7f561c08de6b Initial load
duke
parents:
diff changeset
   250
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   251
   * Given a node handle, get the handle of the node's last child.
7f561c08de6b Initial load
duke
parents:
diff changeset
   252
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   253
   * @param nodeHandle int Handle of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   254
   * @return int Node-number of last child,
7f561c08de6b Initial load
duke
parents:
diff changeset
   255
   * or DTM.NULL to indicate none exists.
7f561c08de6b Initial load
duke
parents:
diff changeset
   256
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   257
  public int getLastChild(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   258
7f561c08de6b Initial load
duke
parents:
diff changeset
   259
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   260
   * Retrieves an attribute node by local name and namespace URI
7f561c08de6b Initial load
duke
parents:
diff changeset
   261
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   262
   * %TBD% Note that we currently have no way to support
7f561c08de6b Initial load
duke
parents:
diff changeset
   263
   * the DOM's old getAttribute() call, which accesses only the qname.
7f561c08de6b Initial load
duke
parents:
diff changeset
   264
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   265
   * @param elementHandle Handle of the node upon which to look up this attribute.
7f561c08de6b Initial load
duke
parents:
diff changeset
   266
   * @param namespaceURI The namespace URI of the attribute to
7f561c08de6b Initial load
duke
parents:
diff changeset
   267
   *   retrieve, or null.
7f561c08de6b Initial load
duke
parents:
diff changeset
   268
   * @param name The local name of the attribute to
7f561c08de6b Initial load
duke
parents:
diff changeset
   269
   *   retrieve.
7f561c08de6b Initial load
duke
parents:
diff changeset
   270
   * @return The attribute node handle with the specified name (
7f561c08de6b Initial load
duke
parents:
diff changeset
   271
   *   <code>nodeName</code>) or <code>DTM.NULL</code> if there is no such
7f561c08de6b Initial load
duke
parents:
diff changeset
   272
   *   attribute.
7f561c08de6b Initial load
duke
parents:
diff changeset
   273
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   274
  public int getAttributeNode(int elementHandle, String namespaceURI,
7f561c08de6b Initial load
duke
parents:
diff changeset
   275
                              String name);
7f561c08de6b Initial load
duke
parents:
diff changeset
   276
7f561c08de6b Initial load
duke
parents:
diff changeset
   277
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   278
   * Given a node handle, get the index of the node's first attribute.
7f561c08de6b Initial load
duke
parents:
diff changeset
   279
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   280
   * @param nodeHandle int Handle of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   281
   * @return Handle of first attribute, or DTM.NULL to indicate none exists.
7f561c08de6b Initial load
duke
parents:
diff changeset
   282
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   283
  public int getFirstAttribute(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   284
7f561c08de6b Initial load
duke
parents:
diff changeset
   285
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   286
   * Given a node handle, get the index of the node's first namespace node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   287
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   288
   * @param nodeHandle handle to node, which should probably be an element
7f561c08de6b Initial load
duke
parents:
diff changeset
   289
   *                   node, but need not be.
7f561c08de6b Initial load
duke
parents:
diff changeset
   290
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   291
   * @param inScope true if all namespaces in scope should be
7f561c08de6b Initial load
duke
parents:
diff changeset
   292
   *                   returned, false if only the node's own
7f561c08de6b Initial load
duke
parents:
diff changeset
   293
   *                   namespace declarations should be returned.
7f561c08de6b Initial load
duke
parents:
diff changeset
   294
   * @return handle of first namespace,
7f561c08de6b Initial load
duke
parents:
diff changeset
   295
   * or DTM.NULL to indicate none exists.
7f561c08de6b Initial load
duke
parents:
diff changeset
   296
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   297
  public int getFirstNamespaceNode(int nodeHandle, boolean inScope);
7f561c08de6b Initial load
duke
parents:
diff changeset
   298
7f561c08de6b Initial load
duke
parents:
diff changeset
   299
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   300
   * Given a node handle, advance to its next sibling.
7f561c08de6b Initial load
duke
parents:
diff changeset
   301
   * @param nodeHandle int Handle of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   302
   * @return int Node-number of next sibling,
7f561c08de6b Initial load
duke
parents:
diff changeset
   303
   * or DTM.NULL to indicate none exists.
7f561c08de6b Initial load
duke
parents:
diff changeset
   304
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   305
  public int getNextSibling(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   306
7f561c08de6b Initial load
duke
parents:
diff changeset
   307
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   308
   * Given a node handle, find its preceeding sibling.
7f561c08de6b Initial load
duke
parents:
diff changeset
   309
   * WARNING: DTM implementations may be asymmetric; in some,
7f561c08de6b Initial load
duke
parents:
diff changeset
   310
   * this operation has been resolved by search, and is relatively expensive.
7f561c08de6b Initial load
duke
parents:
diff changeset
   311
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   312
   * @param nodeHandle the id of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   313
   * @return int Node-number of the previous sib,
7f561c08de6b Initial load
duke
parents:
diff changeset
   314
   * or DTM.NULL to indicate none exists.
7f561c08de6b Initial load
duke
parents:
diff changeset
   315
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   316
  public int getPreviousSibling(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   317
7f561c08de6b Initial load
duke
parents:
diff changeset
   318
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   319
   * Given a node handle, advance to the next attribute. If an
7f561c08de6b Initial load
duke
parents:
diff changeset
   320
   * element, we advance to its first attribute; if an attr, we advance to
7f561c08de6b Initial load
duke
parents:
diff changeset
   321
   * the next attr of the same element.
7f561c08de6b Initial load
duke
parents:
diff changeset
   322
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   323
   * @param nodeHandle int Handle of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   324
   * @return int DTM node-number of the resolved attr,
7f561c08de6b Initial load
duke
parents:
diff changeset
   325
   * or DTM.NULL to indicate none exists.
7f561c08de6b Initial load
duke
parents:
diff changeset
   326
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   327
  public int getNextAttribute(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   328
7f561c08de6b Initial load
duke
parents:
diff changeset
   329
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   330
   * Given a namespace handle, advance to the next namespace in the same scope
7f561c08de6b Initial load
duke
parents:
diff changeset
   331
   * (local or local-plus-inherited, as selected by getFirstNamespaceNode)
7f561c08de6b Initial load
duke
parents:
diff changeset
   332
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   333
   * @param baseHandle handle to original node from where the first child
7f561c08de6b Initial load
duke
parents:
diff changeset
   334
   * was relative to (needed to return nodes in document order).
7f561c08de6b Initial load
duke
parents:
diff changeset
   335
   * @param namespaceHandle handle to node which must be of type
7f561c08de6b Initial load
duke
parents:
diff changeset
   336
   * NAMESPACE_NODE.
7f561c08de6b Initial load
duke
parents:
diff changeset
   337
   * NEEDSDOC @param inScope
7f561c08de6b Initial load
duke
parents:
diff changeset
   338
   * @return handle of next namespace,
7f561c08de6b Initial load
duke
parents:
diff changeset
   339
   * or DTM.NULL to indicate none exists.
7f561c08de6b Initial load
duke
parents:
diff changeset
   340
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   341
  public int getNextNamespaceNode(int baseHandle, int namespaceHandle,
7f561c08de6b Initial load
duke
parents:
diff changeset
   342
                                  boolean inScope);
7f561c08de6b Initial load
duke
parents:
diff changeset
   343
7f561c08de6b Initial load
duke
parents:
diff changeset
   344
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   345
   * Given a node handle, find its parent node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   346
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   347
   * @param nodeHandle the id of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   348
   * @return int Node handle of parent,
7f561c08de6b Initial load
duke
parents:
diff changeset
   349
   * or DTM.NULL to indicate none exists.
7f561c08de6b Initial load
duke
parents:
diff changeset
   350
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   351
  public int getParent(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   352
7f561c08de6b Initial load
duke
parents:
diff changeset
   353
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   354
   * Given a DTM which contains only a single document,
7f561c08de6b Initial load
duke
parents:
diff changeset
   355
   * find the Node Handle of the  Document node. Note
7f561c08de6b Initial load
duke
parents:
diff changeset
   356
   * that if the DTM is configured so it can contain multiple
7f561c08de6b Initial load
duke
parents:
diff changeset
   357
   * documents, this call will return the Document currently
7f561c08de6b Initial load
duke
parents:
diff changeset
   358
   * under construction -- but may return null if it's between
7f561c08de6b Initial load
duke
parents:
diff changeset
   359
   * documents. Generally, you should use getOwnerDocument(nodeHandle)
7f561c08de6b Initial load
duke
parents:
diff changeset
   360
   * or getDocumentRoot(nodeHandle) instead.
7f561c08de6b Initial load
duke
parents:
diff changeset
   361
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   362
   * @return int Node handle of document, or DTM.NULL if a shared DTM
7f561c08de6b Initial load
duke
parents:
diff changeset
   363
   * can not tell us which Document is currently active.
7f561c08de6b Initial load
duke
parents:
diff changeset
   364
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   365
  public int getDocument();
7f561c08de6b Initial load
duke
parents:
diff changeset
   366
7f561c08de6b Initial load
duke
parents:
diff changeset
   367
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   368
   * Given a node handle, find the owning document node. This version mimics
7f561c08de6b Initial load
duke
parents:
diff changeset
   369
   * the behavior of the DOM call by the same name.
7f561c08de6b Initial load
duke
parents:
diff changeset
   370
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   371
   * @param nodeHandle the id of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   372
   * @return int Node handle of owning document, or DTM.NULL if the node was
7f561c08de6b Initial load
duke
parents:
diff changeset
   373
   * a Document.
7f561c08de6b Initial load
duke
parents:
diff changeset
   374
   * @see #getDocumentRoot(int nodeHandle)
7f561c08de6b Initial load
duke
parents:
diff changeset
   375
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   376
  public int getOwnerDocument(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   377
7f561c08de6b Initial load
duke
parents:
diff changeset
   378
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   379
   * Given a node handle, find the owning document node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   380
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   381
   * @param nodeHandle the id of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   382
   * @return int Node handle of owning document, or the node itself if it was
7f561c08de6b Initial load
duke
parents:
diff changeset
   383
   * a Document. (Note difference from DOM, where getOwnerDocument returns
7f561c08de6b Initial load
duke
parents:
diff changeset
   384
   * null for the Document node.)
7f561c08de6b Initial load
duke
parents:
diff changeset
   385
   * @see #getOwnerDocument(int nodeHandle)
7f561c08de6b Initial load
duke
parents:
diff changeset
   386
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   387
  public int getDocumentRoot(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   388
7f561c08de6b Initial load
duke
parents:
diff changeset
   389
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   390
   * Get the string-value of a node as a String object
7f561c08de6b Initial load
duke
parents:
diff changeset
   391
   * (see http://www.w3.org/TR/xpath#data-model
7f561c08de6b Initial load
duke
parents:
diff changeset
   392
   * for the definition of a node's string-value).
7f561c08de6b Initial load
duke
parents:
diff changeset
   393
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   394
   * @param nodeHandle The node ID.
7f561c08de6b Initial load
duke
parents:
diff changeset
   395
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   396
   * @return A string object that represents the string-value of the given node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   397
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   398
  public XMLString getStringValue(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   399
7f561c08de6b Initial load
duke
parents:
diff changeset
   400
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   401
   * Get number of character array chunks in
7f561c08de6b Initial load
duke
parents:
diff changeset
   402
   * the string-value of a node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   403
   * (see http://www.w3.org/TR/xpath#data-model
7f561c08de6b Initial load
duke
parents:
diff changeset
   404
   * for the definition of a node's string-value).
7f561c08de6b Initial load
duke
parents:
diff changeset
   405
   * Note that a single text node may have multiple text chunks.
7f561c08de6b Initial load
duke
parents:
diff changeset
   406
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   407
   * @param nodeHandle The node ID.
7f561c08de6b Initial load
duke
parents:
diff changeset
   408
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   409
   * @return number of character array chunks in
7f561c08de6b Initial load
duke
parents:
diff changeset
   410
   *         the string-value of a node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   411
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   412
  public int getStringValueChunkCount(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   413
7f561c08de6b Initial load
duke
parents:
diff changeset
   414
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   415
   * Get a character array chunk in the string-value of a node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   416
   * (see http://www.w3.org/TR/xpath#data-model
7f561c08de6b Initial load
duke
parents:
diff changeset
   417
   * for the definition of a node's string-value).
7f561c08de6b Initial load
duke
parents:
diff changeset
   418
   * Note that a single text node may have multiple text chunks.
7f561c08de6b Initial load
duke
parents:
diff changeset
   419
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   420
   * @param nodeHandle The node ID.
7f561c08de6b Initial load
duke
parents:
diff changeset
   421
   * @param chunkIndex Which chunk to get.
7f561c08de6b Initial load
duke
parents:
diff changeset
   422
   * @param startAndLen  A two-integer array which, upon return, WILL
7f561c08de6b Initial load
duke
parents:
diff changeset
   423
   * BE FILLED with values representing the chunk's start position
7f561c08de6b Initial load
duke
parents:
diff changeset
   424
   * within the returned character buffer and the length of the chunk.
7f561c08de6b Initial load
duke
parents:
diff changeset
   425
   * @return The character array buffer within which the chunk occurs,
7f561c08de6b Initial load
duke
parents:
diff changeset
   426
   * setting startAndLen's contents as a side-effect.
7f561c08de6b Initial load
duke
parents:
diff changeset
   427
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   428
  public char[] getStringValueChunk(int nodeHandle, int chunkIndex,
7f561c08de6b Initial load
duke
parents:
diff changeset
   429
                                    int[] startAndLen);
7f561c08de6b Initial load
duke
parents:
diff changeset
   430
7f561c08de6b Initial load
duke
parents:
diff changeset
   431
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   432
   * Given a node handle, return an ID that represents the node's expanded name.
7f561c08de6b Initial load
duke
parents:
diff changeset
   433
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   434
   * @param nodeHandle The handle to the node in question.
7f561c08de6b Initial load
duke
parents:
diff changeset
   435
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   436
   * @return the expanded-name id of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   437
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   438
  public int getExpandedTypeID(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   439
7f561c08de6b Initial load
duke
parents:
diff changeset
   440
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   441
   * Given an expanded name, return an ID.  If the expanded-name does not
7f561c08de6b Initial load
duke
parents:
diff changeset
   442
   * exist in the internal tables, the entry will be created, and the ID will
7f561c08de6b Initial load
duke
parents:
diff changeset
   443
   * be returned.  Any additional nodes that are created that have this
7f561c08de6b Initial load
duke
parents:
diff changeset
   444
   * expanded name will use this ID.
7f561c08de6b Initial load
duke
parents:
diff changeset
   445
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   446
   * NEEDSDOC @param namespace
7f561c08de6b Initial load
duke
parents:
diff changeset
   447
   * NEEDSDOC @param localName
7f561c08de6b Initial load
duke
parents:
diff changeset
   448
   * NEEDSDOC @param type
7f561c08de6b Initial load
duke
parents:
diff changeset
   449
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   450
   * @return the expanded-name id of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   451
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   452
  public int getExpandedTypeID(String namespace, String localName, int type);
7f561c08de6b Initial load
duke
parents:
diff changeset
   453
7f561c08de6b Initial load
duke
parents:
diff changeset
   454
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   455
   * Given an expanded-name ID, return the local name part.
7f561c08de6b Initial load
duke
parents:
diff changeset
   456
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   457
   * @param ExpandedNameID an ID that represents an expanded-name.
7f561c08de6b Initial load
duke
parents:
diff changeset
   458
   * @return String Local name of this node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   459
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   460
  public String getLocalNameFromExpandedNameID(int ExpandedNameID);
7f561c08de6b Initial load
duke
parents:
diff changeset
   461
7f561c08de6b Initial load
duke
parents:
diff changeset
   462
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   463
   * Given an expanded-name ID, return the namespace URI part.
7f561c08de6b Initial load
duke
parents:
diff changeset
   464
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   465
   * @param ExpandedNameID an ID that represents an expanded-name.
7f561c08de6b Initial load
duke
parents:
diff changeset
   466
   * @return String URI value of this node's namespace, or null if no
7f561c08de6b Initial load
duke
parents:
diff changeset
   467
   * namespace was resolved.
7f561c08de6b Initial load
duke
parents:
diff changeset
   468
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   469
  public String getNamespaceFromExpandedNameID(int ExpandedNameID);
7f561c08de6b Initial load
duke
parents:
diff changeset
   470
7f561c08de6b Initial load
duke
parents:
diff changeset
   471
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   472
   * Given a node handle, return its DOM-style node name. This will
7f561c08de6b Initial load
duke
parents:
diff changeset
   473
   * include names such as #text or #document.
7f561c08de6b Initial load
duke
parents:
diff changeset
   474
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   475
   * @param nodeHandle the id of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   476
   * @return String Name of this node, which may be an empty string.
7f561c08de6b Initial load
duke
parents:
diff changeset
   477
   * %REVIEW% Document when empty string is possible...
7f561c08de6b Initial load
duke
parents:
diff changeset
   478
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   479
  public String getNodeName(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   480
7f561c08de6b Initial load
duke
parents:
diff changeset
   481
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   482
   * Given a node handle, return the XPath node name.  This should be
7f561c08de6b Initial load
duke
parents:
diff changeset
   483
   * the name as described by the XPath data model, NOT the DOM-style
7f561c08de6b Initial load
duke
parents:
diff changeset
   484
   * name.
7f561c08de6b Initial load
duke
parents:
diff changeset
   485
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   486
   * @param nodeHandle the id of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   487
   * @return String Name of this node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   488
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   489
  public String getNodeNameX(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   490
7f561c08de6b Initial load
duke
parents:
diff changeset
   491
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   492
   * Given a node handle, return its DOM-style localname.
7f561c08de6b Initial load
duke
parents:
diff changeset
   493
   * (As defined in Namespaces, this is the portion of the name after the
7f561c08de6b Initial load
duke
parents:
diff changeset
   494
   * prefix, if present, or the whole node name if no prefix exists)
7f561c08de6b Initial load
duke
parents:
diff changeset
   495
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   496
   * @param nodeHandle the id of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   497
   * @return String Local name of this node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   498
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   499
  public String getLocalName(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   500
7f561c08de6b Initial load
duke
parents:
diff changeset
   501
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   502
   * Given a namespace handle, return the prefix that the namespace decl is
7f561c08de6b Initial load
duke
parents:
diff changeset
   503
   * mapping.
7f561c08de6b Initial load
duke
parents:
diff changeset
   504
   * Given a node handle, return the prefix used to map to the namespace.
7f561c08de6b Initial load
duke
parents:
diff changeset
   505
   * (As defined in Namespaces, this is the portion of the name before any
7f561c08de6b Initial load
duke
parents:
diff changeset
   506
   * colon character).
7f561c08de6b Initial load
duke
parents:
diff changeset
   507
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   508
   * <p> %REVIEW% Are you sure you want "" for no prefix?  </p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   509
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   510
   * @param nodeHandle the id of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   511
   * @return String prefix of this node's name, or "" if no explicit
7f561c08de6b Initial load
duke
parents:
diff changeset
   512
   * namespace prefix was given.
7f561c08de6b Initial load
duke
parents:
diff changeset
   513
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   514
  public String getPrefix(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   515
7f561c08de6b Initial load
duke
parents:
diff changeset
   516
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   517
   * Given a node handle, return its DOM-style namespace URI
7f561c08de6b Initial load
duke
parents:
diff changeset
   518
   * (As defined in Namespaces, this is the declared URI which this node's
7f561c08de6b Initial load
duke
parents:
diff changeset
   519
   * prefix -- or default in lieu thereof -- was mapped to.)
7f561c08de6b Initial load
duke
parents:
diff changeset
   520
   * @param nodeHandle the id of the node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   521
   * @return String URI value of this node's namespace, or null if no
7f561c08de6b Initial load
duke
parents:
diff changeset
   522
   * namespace was resolved.
7f561c08de6b Initial load
duke
parents:
diff changeset
   523
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   524
  public String getNamespaceURI(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   525
7f561c08de6b Initial load
duke
parents:
diff changeset
   526
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   527
   * Given a node handle, return its node value. This is mostly
7f561c08de6b Initial load
duke
parents:
diff changeset
   528
   * as defined by the DOM, but may ignore some conveniences.
7f561c08de6b Initial load
duke
parents:
diff changeset
   529
   * <p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   530
   * @param nodeHandle The node id.
7f561c08de6b Initial load
duke
parents:
diff changeset
   531
   * @return String Value of this node, or null if not
7f561c08de6b Initial load
duke
parents:
diff changeset
   532
   * meaningful for this node type.
7f561c08de6b Initial load
duke
parents:
diff changeset
   533
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   534
  public String getNodeValue(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   535
7f561c08de6b Initial load
duke
parents:
diff changeset
   536
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   537
   * Given a node handle, return its DOM-style node type.
7f561c08de6b Initial load
duke
parents:
diff changeset
   538
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   539
   * <p>%REVIEW% Generally, returning short is false economy. Return int?</p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   540
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   541
   * @param nodeHandle The node id.
7f561c08de6b Initial load
duke
parents:
diff changeset
   542
   * @return int Node type, as per the DOM's Node._NODE constants.
7f561c08de6b Initial load
duke
parents:
diff changeset
   543
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   544
  public short getNodeType(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   545
7f561c08de6b Initial load
duke
parents:
diff changeset
   546
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   547
   * Get the depth level of this node in the tree (equals 1 for
7f561c08de6b Initial load
duke
parents:
diff changeset
   548
   * a parentless node).
7f561c08de6b Initial load
duke
parents:
diff changeset
   549
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   550
   * @param nodeHandle The node id.
7f561c08de6b Initial load
duke
parents:
diff changeset
   551
   * @return the number of ancestors, plus one
7f561c08de6b Initial load
duke
parents:
diff changeset
   552
   * @xsl.usage internal
7f561c08de6b Initial load
duke
parents:
diff changeset
   553
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   554
  public short getLevel(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   555
7f561c08de6b Initial load
duke
parents:
diff changeset
   556
  // ============== Document query functions ==============
7f561c08de6b Initial load
duke
parents:
diff changeset
   557
7f561c08de6b Initial load
duke
parents:
diff changeset
   558
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   559
   * Tests whether DTM DOM implementation implements a specific feature and
7f561c08de6b Initial load
duke
parents:
diff changeset
   560
   * that feature is supported by this node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   561
   * @param feature The name of the feature to test.
7f561c08de6b Initial load
duke
parents:
diff changeset
   562
   * @param version This is the version number of the feature to test.
7f561c08de6b Initial load
duke
parents:
diff changeset
   563
   *   If the version is not
7f561c08de6b Initial load
duke
parents:
diff changeset
   564
   *   specified, supporting any version of the feature will cause the
7f561c08de6b Initial load
duke
parents:
diff changeset
   565
   *   method to return <code>true</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   566
   * @return Returns <code>true</code> if the specified feature is
7f561c08de6b Initial load
duke
parents:
diff changeset
   567
   *   supported on this node, <code>false</code> otherwise.
7f561c08de6b Initial load
duke
parents:
diff changeset
   568
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   569
  public boolean isSupported(String feature, String version);
7f561c08de6b Initial load
duke
parents:
diff changeset
   570
7f561c08de6b Initial load
duke
parents:
diff changeset
   571
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   572
   * Return the base URI of the document entity. If it is not known
7f561c08de6b Initial load
duke
parents:
diff changeset
   573
   * (because the document was parsed from a socket connection or from
7f561c08de6b Initial load
duke
parents:
diff changeset
   574
   * standard input, for example), the value of this property is unknown.
7f561c08de6b Initial load
duke
parents:
diff changeset
   575
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   576
   * @return the document base URI String object or null if unknown.
7f561c08de6b Initial load
duke
parents:
diff changeset
   577
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   578
  public String getDocumentBaseURI();
7f561c08de6b Initial load
duke
parents:
diff changeset
   579
7f561c08de6b Initial load
duke
parents:
diff changeset
   580
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   581
   * Set the base URI of the document entity.
7f561c08de6b Initial load
duke
parents:
diff changeset
   582
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   583
   * @param baseURI the document base URI String object or null if unknown.
7f561c08de6b Initial load
duke
parents:
diff changeset
   584
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   585
  public void setDocumentBaseURI(String baseURI);
7f561c08de6b Initial load
duke
parents:
diff changeset
   586
7f561c08de6b Initial load
duke
parents:
diff changeset
   587
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   588
   * Return the system identifier of the document entity. If
7f561c08de6b Initial load
duke
parents:
diff changeset
   589
   * it is not known, the value of this property is null.
7f561c08de6b Initial load
duke
parents:
diff changeset
   590
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   591
   * @param nodeHandle The node id, which can be any valid node handle.
7f561c08de6b Initial load
duke
parents:
diff changeset
   592
   * @return the system identifier String object or null if unknown.
7f561c08de6b Initial load
duke
parents:
diff changeset
   593
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   594
  public String getDocumentSystemIdentifier(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   595
7f561c08de6b Initial load
duke
parents:
diff changeset
   596
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   597
   * Return the name of the character encoding scheme
7f561c08de6b Initial load
duke
parents:
diff changeset
   598
   *        in which the document entity is expressed.
7f561c08de6b Initial load
duke
parents:
diff changeset
   599
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   600
   * @param nodeHandle The node id, which can be any valid node handle.
7f561c08de6b Initial load
duke
parents:
diff changeset
   601
   * @return the document encoding String object.
7f561c08de6b Initial load
duke
parents:
diff changeset
   602
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   603
  public String getDocumentEncoding(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   604
7f561c08de6b Initial load
duke
parents:
diff changeset
   605
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   606
   * Return an indication of the standalone status of the document,
7f561c08de6b Initial load
duke
parents:
diff changeset
   607
   *        either "yes" or "no". This property is derived from the optional
7f561c08de6b Initial load
duke
parents:
diff changeset
   608
   *        standalone document declaration in the XML declaration at the
7f561c08de6b Initial load
duke
parents:
diff changeset
   609
   *        beginning of the document entity, and has no value if there is no
7f561c08de6b Initial load
duke
parents:
diff changeset
   610
   *        standalone document declaration.
7f561c08de6b Initial load
duke
parents:
diff changeset
   611
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   612
   * @param nodeHandle The node id, which can be any valid node handle.
7f561c08de6b Initial load
duke
parents:
diff changeset
   613
   * @return the document standalone String object, either "yes", "no", or null.
7f561c08de6b Initial load
duke
parents:
diff changeset
   614
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   615
  public String getDocumentStandalone(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   616
7f561c08de6b Initial load
duke
parents:
diff changeset
   617
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   618
   * Return a string representing the XML version of the document. This
7f561c08de6b Initial load
duke
parents:
diff changeset
   619
   * property is derived from the XML declaration optionally present at the
7f561c08de6b Initial load
duke
parents:
diff changeset
   620
   * beginning of the document entity, and has no value if there is no XML
7f561c08de6b Initial load
duke
parents:
diff changeset
   621
   * declaration.
7f561c08de6b Initial load
duke
parents:
diff changeset
   622
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   623
   * @param documentHandle the document handle
7f561c08de6b Initial load
duke
parents:
diff changeset
   624
   * @return the document version String object
7f561c08de6b Initial load
duke
parents:
diff changeset
   625
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   626
  public String getDocumentVersion(int documentHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   627
7f561c08de6b Initial load
duke
parents:
diff changeset
   628
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   629
   * Return an indication of
7f561c08de6b Initial load
duke
parents:
diff changeset
   630
   * whether the processor has read the complete DTD. Its value is a
7f561c08de6b Initial load
duke
parents:
diff changeset
   631
   * boolean. If it is false, then certain properties (indicated in their
7f561c08de6b Initial load
duke
parents:
diff changeset
   632
   * descriptions below) may be unknown. If it is true, those properties
7f561c08de6b Initial load
duke
parents:
diff changeset
   633
   * are never unknown.
7f561c08de6b Initial load
duke
parents:
diff changeset
   634
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   635
   * @return <code>true</code> if all declarations were processed;
7f561c08de6b Initial load
duke
parents:
diff changeset
   636
   *         <code>false</code> otherwise.
7f561c08de6b Initial load
duke
parents:
diff changeset
   637
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   638
  public boolean getDocumentAllDeclarationsProcessed();
7f561c08de6b Initial load
duke
parents:
diff changeset
   639
7f561c08de6b Initial load
duke
parents:
diff changeset
   640
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   641
   *   A document type declaration information item has the following properties:
7f561c08de6b Initial load
duke
parents:
diff changeset
   642
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   643
   *     1. [system identifier] The system identifier of the external subset, if
7f561c08de6b Initial load
duke
parents:
diff changeset
   644
   *        it exists. Otherwise this property has no value.
7f561c08de6b Initial load
duke
parents:
diff changeset
   645
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   646
   * @return the system identifier String object, or null if there is none.
7f561c08de6b Initial load
duke
parents:
diff changeset
   647
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   648
  public String getDocumentTypeDeclarationSystemIdentifier();
7f561c08de6b Initial load
duke
parents:
diff changeset
   649
7f561c08de6b Initial load
duke
parents:
diff changeset
   650
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   651
   * Return the public identifier of the external subset,
7f561c08de6b Initial load
duke
parents:
diff changeset
   652
   * normalized as described in 4.2.2 External Entities [XML]. If there is
7f561c08de6b Initial load
duke
parents:
diff changeset
   653
   * no external subset or if it has no public identifier, this property
7f561c08de6b Initial load
duke
parents:
diff changeset
   654
   * has no value.
7f561c08de6b Initial load
duke
parents:
diff changeset
   655
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   656
   * @return the public identifier String object, or null if there is none.
7f561c08de6b Initial load
duke
parents:
diff changeset
   657
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   658
  public String getDocumentTypeDeclarationPublicIdentifier();
7f561c08de6b Initial load
duke
parents:
diff changeset
   659
7f561c08de6b Initial load
duke
parents:
diff changeset
   660
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   661
   * Returns the <code>Element</code> whose <code>ID</code> is given by
7f561c08de6b Initial load
duke
parents:
diff changeset
   662
   * <code>elementId</code>. If no such element exists, returns
7f561c08de6b Initial load
duke
parents:
diff changeset
   663
   * <code>DTM.NULL</code>. Behavior is not defined if more than one element
7f561c08de6b Initial load
duke
parents:
diff changeset
   664
   * has this <code>ID</code>. Attributes (including those
7f561c08de6b Initial load
duke
parents:
diff changeset
   665
   * with the name "ID") are not of type ID unless so defined by DTD/Schema
7f561c08de6b Initial load
duke
parents:
diff changeset
   666
   * information available to the DTM implementation.
7f561c08de6b Initial load
duke
parents:
diff changeset
   667
   * Implementations that do not know whether attributes are of type ID or
7f561c08de6b Initial load
duke
parents:
diff changeset
   668
   * not are expected to return <code>DTM.NULL</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   669
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   670
   * <p>%REVIEW% Presumably IDs are still scoped to a single document,
7f561c08de6b Initial load
duke
parents:
diff changeset
   671
   * and this operation searches only within a single document, right?
7f561c08de6b Initial load
duke
parents:
diff changeset
   672
   * Wouldn't want collisions between DTMs in the same process.</p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   673
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   674
   * @param elementId The unique <code>id</code> value for an element.
7f561c08de6b Initial load
duke
parents:
diff changeset
   675
   * @return The handle of the matching element.
7f561c08de6b Initial load
duke
parents:
diff changeset
   676
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   677
  public int getElementById(String elementId);
7f561c08de6b Initial load
duke
parents:
diff changeset
   678
7f561c08de6b Initial load
duke
parents:
diff changeset
   679
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   680
   * The getUnparsedEntityURI function returns the URI of the unparsed
7f561c08de6b Initial load
duke
parents:
diff changeset
   681
   * entity with the specified name in the same document as the context
7f561c08de6b Initial load
duke
parents:
diff changeset
   682
   * node (see [3.3 Unparsed Entities]). It returns the empty string if
7f561c08de6b Initial load
duke
parents:
diff changeset
   683
   * there is no such entity.
7f561c08de6b Initial load
duke
parents:
diff changeset
   684
   * <p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   685
   * XML processors may choose to use the System Identifier (if one
7f561c08de6b Initial load
duke
parents:
diff changeset
   686
   * is provided) to resolve the entity, rather than the URI in the
7f561c08de6b Initial load
duke
parents:
diff changeset
   687
   * Public Identifier. The details are dependent on the processor, and
7f561c08de6b Initial load
duke
parents:
diff changeset
   688
   * we would have to support some form of plug-in resolver to handle
7f561c08de6b Initial load
duke
parents:
diff changeset
   689
   * this properly. Currently, we simply return the System Identifier if
7f561c08de6b Initial load
duke
parents:
diff changeset
   690
   * present, and hope that it a usable URI or that our caller can
7f561c08de6b Initial load
duke
parents:
diff changeset
   691
   * map it to one.
7f561c08de6b Initial load
duke
parents:
diff changeset
   692
   * %REVIEW% Resolve Public Identifiers... or consider changing function name.
7f561c08de6b Initial load
duke
parents:
diff changeset
   693
   * <p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   694
   * If we find a relative URI
7f561c08de6b Initial load
duke
parents:
diff changeset
   695
   * reference, XML expects it to be resolved in terms of the base URI
7f561c08de6b Initial load
duke
parents:
diff changeset
   696
   * of the document. The DOM doesn't do that for us, and it isn't
7f561c08de6b Initial load
duke
parents:
diff changeset
   697
   * entirely clear whether that should be done here; currently that's
7f561c08de6b Initial load
duke
parents:
diff changeset
   698
   * pushed up to a higher level of our application. (Note that DOM Level
7f561c08de6b Initial load
duke
parents:
diff changeset
   699
   * 1 didn't store the document's base URI.)
7f561c08de6b Initial load
duke
parents:
diff changeset
   700
   * %REVIEW% Consider resolving Relative URIs.
7f561c08de6b Initial load
duke
parents:
diff changeset
   701
   * <p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   702
   * (The DOM's statement that "An XML processor may choose to
7f561c08de6b Initial load
duke
parents:
diff changeset
   703
   * completely expand entities before the structure model is passed
7f561c08de6b Initial load
duke
parents:
diff changeset
   704
   * to the DOM" refers only to parsed entities, not unparsed, and hence
7f561c08de6b Initial load
duke
parents:
diff changeset
   705
   * doesn't affect this function.)
7f561c08de6b Initial load
duke
parents:
diff changeset
   706
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   707
   * @param name A string containing the Entity Name of the unparsed
7f561c08de6b Initial load
duke
parents:
diff changeset
   708
   * entity.
7f561c08de6b Initial load
duke
parents:
diff changeset
   709
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   710
   * @return String containing the URI of the Unparsed Entity, or an
7f561c08de6b Initial load
duke
parents:
diff changeset
   711
   * empty string if no such entity exists.
7f561c08de6b Initial load
duke
parents:
diff changeset
   712
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   713
  public String getUnparsedEntityURI(String name);
7f561c08de6b Initial load
duke
parents:
diff changeset
   714
7f561c08de6b Initial load
duke
parents:
diff changeset
   715
  // ============== Boolean methods ================
7f561c08de6b Initial load
duke
parents:
diff changeset
   716
7f561c08de6b Initial load
duke
parents:
diff changeset
   717
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   718
   * Return true if the xsl:strip-space or xsl:preserve-space was processed
7f561c08de6b Initial load
duke
parents:
diff changeset
   719
   * during construction of the document contained in this DTM.
7f561c08de6b Initial load
duke
parents:
diff changeset
   720
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   721
   * NEEDSDOC ($objectName$) @return
7f561c08de6b Initial load
duke
parents:
diff changeset
   722
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   723
  public boolean supportsPreStripping();
7f561c08de6b Initial load
duke
parents:
diff changeset
   724
7f561c08de6b Initial load
duke
parents:
diff changeset
   725
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   726
   * Figure out whether nodeHandle2 should be considered as being later
7f561c08de6b Initial load
duke
parents:
diff changeset
   727
   * in the document than nodeHandle1, in Document Order as defined
7f561c08de6b Initial load
duke
parents:
diff changeset
   728
   * by the XPath model. This may not agree with the ordering defined
7f561c08de6b Initial load
duke
parents:
diff changeset
   729
   * by other XML applications.
7f561c08de6b Initial load
duke
parents:
diff changeset
   730
   * <p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   731
   * There are some cases where ordering isn't defined, and neither are
7f561c08de6b Initial load
duke
parents:
diff changeset
   732
   * the results of this function -- though we'll generally return true.
7f561c08de6b Initial load
duke
parents:
diff changeset
   733
   * <p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   734
   * %REVIEW% Make sure this does the right thing with attribute nodes!!!
7f561c08de6b Initial load
duke
parents:
diff changeset
   735
   * <p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   736
   * %REVIEW% Consider renaming for clarity. Perhaps isDocumentOrder(a,b)?
7f561c08de6b Initial load
duke
parents:
diff changeset
   737
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   738
   * @param firstNodeHandle DOM Node to perform position comparison on.
7f561c08de6b Initial load
duke
parents:
diff changeset
   739
   * @param secondNodeHandle DOM Node to perform position comparison on.
7f561c08de6b Initial load
duke
parents:
diff changeset
   740
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   741
   * @return false if secondNode comes before firstNode, otherwise return true.
7f561c08de6b Initial load
duke
parents:
diff changeset
   742
   * You can think of this as
7f561c08de6b Initial load
duke
parents:
diff changeset
   743
   * <code>(firstNode.documentOrderPosition &lt;= secondNode.documentOrderPosition)</code>.
7f561c08de6b Initial load
duke
parents:
diff changeset
   744
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   745
  public boolean isNodeAfter(int firstNodeHandle, int secondNodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   746
7f561c08de6b Initial load
duke
parents:
diff changeset
   747
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   748
   * 2. [element content whitespace] A boolean indicating whether a
7f561c08de6b Initial load
duke
parents:
diff changeset
   749
   * text node represents white space appearing within element content
7f561c08de6b Initial load
duke
parents:
diff changeset
   750
   * (see [XML], 2.10 "White Space Handling").  Note that validating
7f561c08de6b Initial load
duke
parents:
diff changeset
   751
   * XML processors are required by XML 1.0 to provide this
7f561c08de6b Initial load
duke
parents:
diff changeset
   752
   * information... but that DOM Level 2 did not support it, since it
7f561c08de6b Initial load
duke
parents:
diff changeset
   753
   * depends on knowledge of the DTD which DOM2 could not guarantee
7f561c08de6b Initial load
duke
parents:
diff changeset
   754
   * would be available.
7f561c08de6b Initial load
duke
parents:
diff changeset
   755
   * <p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   756
   * If there is no declaration for the containing element, an XML
7f561c08de6b Initial load
duke
parents:
diff changeset
   757
   * processor must assume that the whitespace could be meaningful and
7f561c08de6b Initial load
duke
parents:
diff changeset
   758
   * return false. If no declaration has been read, but the [all
7f561c08de6b Initial load
duke
parents:
diff changeset
   759
   * declarations processed] property of the document information item
7f561c08de6b Initial load
duke
parents:
diff changeset
   760
   * is false (so there may be an unread declaration), then the value
7f561c08de6b Initial load
duke
parents:
diff changeset
   761
   * of this property is indeterminate for white space characters and
7f561c08de6b Initial load
duke
parents:
diff changeset
   762
   * should probably be reported as false. It is always false for text
7f561c08de6b Initial load
duke
parents:
diff changeset
   763
   * nodes that contain anything other than (or in addition to) white
7f561c08de6b Initial load
duke
parents:
diff changeset
   764
   * space.
7f561c08de6b Initial load
duke
parents:
diff changeset
   765
   * <p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   766
   * Note too that it always returns false for non-Text nodes.
7f561c08de6b Initial load
duke
parents:
diff changeset
   767
   * <p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   768
   * %REVIEW% Joe wants to rename this isWhitespaceInElementContent() for clarity
7f561c08de6b Initial load
duke
parents:
diff changeset
   769
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   770
   * @param nodeHandle the node ID.
7f561c08de6b Initial load
duke
parents:
diff changeset
   771
   * @return <code>true</code> if the node definitely represents whitespace in
7f561c08de6b Initial load
duke
parents:
diff changeset
   772
   * element content; <code>false</code> otherwise.
7f561c08de6b Initial load
duke
parents:
diff changeset
   773
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   774
  public boolean isCharacterElementContentWhitespace(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   775
7f561c08de6b Initial load
duke
parents:
diff changeset
   776
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   777
   *    10. [all declarations processed] This property is not strictly speaking
7f561c08de6b Initial load
duke
parents:
diff changeset
   778
   *        part of the infoset of the document. Rather it is an indication of
7f561c08de6b Initial load
duke
parents:
diff changeset
   779
   *        whether the processor has read the complete DTD. Its value is a
7f561c08de6b Initial load
duke
parents:
diff changeset
   780
   *        boolean. If it is false, then certain properties (indicated in their
7f561c08de6b Initial load
duke
parents:
diff changeset
   781
   *        descriptions below) may be unknown. If it is true, those properties
7f561c08de6b Initial load
duke
parents:
diff changeset
   782
   *        are never unknown.
7f561c08de6b Initial load
duke
parents:
diff changeset
   783
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   784
   * @param documentHandle A node handle that must identify a document.
7f561c08de6b Initial load
duke
parents:
diff changeset
   785
   * @return <code>true</code> if all declarations were processed;
7f561c08de6b Initial load
duke
parents:
diff changeset
   786
   *         <code>false</code> otherwise.
7f561c08de6b Initial load
duke
parents:
diff changeset
   787
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   788
  public boolean isDocumentAllDeclarationsProcessed(int documentHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   789
7f561c08de6b Initial load
duke
parents:
diff changeset
   790
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   791
   *     5. [specified] A flag indicating whether this attribute was actually
7f561c08de6b Initial load
duke
parents:
diff changeset
   792
   *        specified in the start-tag of its element, or was defaulted from the
7f561c08de6b Initial load
duke
parents:
diff changeset
   793
   *        DTD (or schema).
7f561c08de6b Initial load
duke
parents:
diff changeset
   794
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   795
   * @param attributeHandle The attribute handle
7f561c08de6b Initial load
duke
parents:
diff changeset
   796
   * @return <code>true</code> if the attribute was specified;
7f561c08de6b Initial load
duke
parents:
diff changeset
   797
   *         <code>false</code> if it was defaulted or the handle doesn't
7f561c08de6b Initial load
duke
parents:
diff changeset
   798
   *            refer to an attribute node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   799
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   800
  public boolean isAttributeSpecified(int attributeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   801
7f561c08de6b Initial load
duke
parents:
diff changeset
   802
  // ========== Direct SAX Dispatch, for optimization purposes ========
7f561c08de6b Initial load
duke
parents:
diff changeset
   803
7f561c08de6b Initial load
duke
parents:
diff changeset
   804
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   805
   * Directly call the
7f561c08de6b Initial load
duke
parents:
diff changeset
   806
   * characters method on the passed ContentHandler for the
7f561c08de6b Initial load
duke
parents:
diff changeset
   807
   * string-value of the given node (see http://www.w3.org/TR/xpath#data-model
7f561c08de6b Initial load
duke
parents:
diff changeset
   808
   * for the definition of a node's string-value). Multiple calls to the
7f561c08de6b Initial load
duke
parents:
diff changeset
   809
   * ContentHandler's characters methods may well occur for a single call to
7f561c08de6b Initial load
duke
parents:
diff changeset
   810
   * this method.
7f561c08de6b Initial load
duke
parents:
diff changeset
   811
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   812
   * @param nodeHandle The node ID.
7f561c08de6b Initial load
duke
parents:
diff changeset
   813
   * @param ch A non-null reference to a ContentHandler.
7f561c08de6b Initial load
duke
parents:
diff changeset
   814
   * @param normalize true if the content should be normalized according to
7f561c08de6b Initial load
duke
parents:
diff changeset
   815
   * the rules for the XPath
7f561c08de6b Initial load
duke
parents:
diff changeset
   816
   * <a href="http://www.w3.org/TR/xpath#function-normalize-space">normalize-space</a>
7f561c08de6b Initial load
duke
parents:
diff changeset
   817
   * function.
7f561c08de6b Initial load
duke
parents:
diff changeset
   818
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   819
   * @throws org.xml.sax.SAXException
7f561c08de6b Initial load
duke
parents:
diff changeset
   820
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   821
  public void dispatchCharactersEvents(
7f561c08de6b Initial load
duke
parents:
diff changeset
   822
    int nodeHandle, org.xml.sax.ContentHandler ch, boolean normalize)
7f561c08de6b Initial load
duke
parents:
diff changeset
   823
      throws org.xml.sax.SAXException;
7f561c08de6b Initial load
duke
parents:
diff changeset
   824
7f561c08de6b Initial load
duke
parents:
diff changeset
   825
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   826
   * Directly create SAX parser events representing the XML content of
7f561c08de6b Initial load
duke
parents:
diff changeset
   827
   * a DTM subtree. This is a "serialize" operation.
7f561c08de6b Initial load
duke
parents:
diff changeset
   828
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   829
   * @param nodeHandle The node ID.
7f561c08de6b Initial load
duke
parents:
diff changeset
   830
   * @param ch A non-null reference to a ContentHandler.
7f561c08de6b Initial load
duke
parents:
diff changeset
   831
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   832
   * @throws org.xml.sax.SAXException
7f561c08de6b Initial load
duke
parents:
diff changeset
   833
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   834
  public void dispatchToEvents(int nodeHandle, org.xml.sax.ContentHandler ch)
7f561c08de6b Initial load
duke
parents:
diff changeset
   835
    throws org.xml.sax.SAXException;
7f561c08de6b Initial load
duke
parents:
diff changeset
   836
7f561c08de6b Initial load
duke
parents:
diff changeset
   837
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   838
   * Return an DOM node for the given node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   839
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   840
   * @param nodeHandle The node ID.
7f561c08de6b Initial load
duke
parents:
diff changeset
   841
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   842
   * @return A node representation of the DTM node.
7f561c08de6b Initial load
duke
parents:
diff changeset
   843
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   844
  public org.w3c.dom.Node getNode(int nodeHandle);
7f561c08de6b Initial load
duke
parents:
diff changeset
   845
7f561c08de6b Initial load
duke
parents:
diff changeset
   846
  // ==== Construction methods (may not be supported by some implementations!) =====
7f561c08de6b Initial load
duke
parents:
diff changeset
   847
  // %REVIEW% What response occurs if not supported?
7f561c08de6b Initial load
duke
parents:
diff changeset
   848
7f561c08de6b Initial load
duke
parents:
diff changeset
   849
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   850
   * @return true iff we're building this model incrementally (eg
7f561c08de6b Initial load
duke
parents:
diff changeset
   851
   * we're partnered with a CoroutineParser) and thus require that the
7f561c08de6b Initial load
duke
parents:
diff changeset
   852
   * transformation and the parse run simultaneously. Guidance to the
7f561c08de6b Initial load
duke
parents:
diff changeset
   853
   * DTMManager.
7f561c08de6b Initial load
duke
parents:
diff changeset
   854
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   855
  public boolean needsTwoThreads();
7f561c08de6b Initial load
duke
parents:
diff changeset
   856
7f561c08de6b Initial load
duke
parents:
diff changeset
   857
  // %REVIEW% Do these appends make any sense, should we support a
7f561c08de6b Initial load
duke
parents:
diff changeset
   858
  // wider set of methods (like the "append" methods in the
7f561c08de6b Initial load
duke
parents:
diff changeset
   859
  // current DTMDocumentImpl draft), or should we just support SAX
7f561c08de6b Initial load
duke
parents:
diff changeset
   860
  // listener interfaces?  Should it be a separate interface to
7f561c08de6b Initial load
duke
parents:
diff changeset
   861
  // make that distinction explicit?
7f561c08de6b Initial load
duke
parents:
diff changeset
   862
7f561c08de6b Initial load
duke
parents:
diff changeset
   863
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   864
   * Return this DTM's content handler, if it has one.
7f561c08de6b Initial load
duke
parents:
diff changeset
   865
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   866
   * @return null if this model doesn't respond to SAX events.
7f561c08de6b Initial load
duke
parents:
diff changeset
   867
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   868
  public org.xml.sax.ContentHandler getContentHandler();
7f561c08de6b Initial load
duke
parents:
diff changeset
   869
7f561c08de6b Initial load
duke
parents:
diff changeset
   870
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   871
   * Return this DTM's lexical handler, if it has one.
7f561c08de6b Initial load
duke
parents:
diff changeset
   872
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   873
   * %REVIEW% Should this return null if constrution already done/begun?
7f561c08de6b Initial load
duke
parents:
diff changeset
   874
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   875
   * @return null if this model doesn't respond to lexical SAX events.
7f561c08de6b Initial load
duke
parents:
diff changeset
   876
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   877
  public org.xml.sax.ext.LexicalHandler getLexicalHandler();
7f561c08de6b Initial load
duke
parents:
diff changeset
   878
7f561c08de6b Initial load
duke
parents:
diff changeset
   879
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   880
   * Return this DTM's EntityResolver, if it has one.
7f561c08de6b Initial load
duke
parents:
diff changeset
   881
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   882
   * @return null if this model doesn't respond to SAX entity ref events.
7f561c08de6b Initial load
duke
parents:
diff changeset
   883
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   884
  public org.xml.sax.EntityResolver getEntityResolver();
7f561c08de6b Initial load
duke
parents:
diff changeset
   885
7f561c08de6b Initial load
duke
parents:
diff changeset
   886
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   887
   * Return this DTM's DTDHandler, if it has one.
7f561c08de6b Initial load
duke
parents:
diff changeset
   888
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   889
   * @return null if this model doesn't respond to SAX dtd events.
7f561c08de6b Initial load
duke
parents:
diff changeset
   890
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   891
  public org.xml.sax.DTDHandler getDTDHandler();
7f561c08de6b Initial load
duke
parents:
diff changeset
   892
7f561c08de6b Initial load
duke
parents:
diff changeset
   893
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   894
   * Return this DTM's ErrorHandler, if it has one.
7f561c08de6b Initial load
duke
parents:
diff changeset
   895
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   896
   * @return null if this model doesn't respond to SAX error events.
7f561c08de6b Initial load
duke
parents:
diff changeset
   897
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   898
  public org.xml.sax.ErrorHandler getErrorHandler();
7f561c08de6b Initial load
duke
parents:
diff changeset
   899
7f561c08de6b Initial load
duke
parents:
diff changeset
   900
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   901
   * Return this DTM's DeclHandler, if it has one.
7f561c08de6b Initial load
duke
parents:
diff changeset
   902
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   903
   * @return null if this model doesn't respond to SAX Decl events.
7f561c08de6b Initial load
duke
parents:
diff changeset
   904
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   905
  public org.xml.sax.ext.DeclHandler getDeclHandler();
7f561c08de6b Initial load
duke
parents:
diff changeset
   906
7f561c08de6b Initial load
duke
parents:
diff changeset
   907
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   908
   * Append a child to "the end of the document". Please note that
7f561c08de6b Initial load
duke
parents:
diff changeset
   909
   * the node is always cloned in a base DTM, since our basic behavior
7f561c08de6b Initial load
duke
parents:
diff changeset
   910
   * is immutable so nodes can't be removed from their previous
7f561c08de6b Initial load
duke
parents:
diff changeset
   911
   * location.
7f561c08de6b Initial load
duke
parents:
diff changeset
   912
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   913
   * <p> %REVIEW%  DTM maintains an insertion cursor which
7f561c08de6b Initial load
duke
parents:
diff changeset
   914
   * performs a depth-first tree walk as nodes come in, and this operation
7f561c08de6b Initial load
duke
parents:
diff changeset
   915
   * is really equivalent to:
7f561c08de6b Initial load
duke
parents:
diff changeset
   916
   *    insertionCursor.appendChild(document.importNode(newChild)))
7f561c08de6b Initial load
duke
parents:
diff changeset
   917
   * where the insert point is the last element that was appended (or
7f561c08de6b Initial load
duke
parents:
diff changeset
   918
   * the last one popped back to by an end-element operation).</p>
7f561c08de6b Initial load
duke
parents:
diff changeset
   919
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   920
   * @param newChild Must be a valid new node handle.
7f561c08de6b Initial load
duke
parents:
diff changeset
   921
   * @param clone true if the child should be cloned into the document.
7f561c08de6b Initial load
duke
parents:
diff changeset
   922
   * @param cloneDepth if the clone argument is true, specifies that the
7f561c08de6b Initial load
duke
parents:
diff changeset
   923
   *                   clone should include all it's children.
7f561c08de6b Initial load
duke
parents:
diff changeset
   924
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   925
  public void appendChild(int newChild, boolean clone, boolean cloneDepth);
7f561c08de6b Initial load
duke
parents:
diff changeset
   926
7f561c08de6b Initial load
duke
parents:
diff changeset
   927
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   928
   * Append a text node child that will be constructed from a string,
7f561c08de6b Initial load
duke
parents:
diff changeset
   929
   * to the end of the document. Behavior is otherwise like appendChild().
7f561c08de6b Initial load
duke
parents:
diff changeset
   930
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   931
   * @param str Non-null reference to a string.
7f561c08de6b Initial load
duke
parents:
diff changeset
   932
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   933
  public void appendTextChild(String str);
7f561c08de6b Initial load
duke
parents:
diff changeset
   934
7f561c08de6b Initial load
duke
parents:
diff changeset
   935
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   936
   * Get the location of a node in the source document.
7f561c08de6b Initial load
duke
parents:
diff changeset
   937
   *
7f561c08de6b Initial load
duke
parents:
diff changeset
   938
   * @param node an <code>int</code> value
7f561c08de6b Initial load
duke
parents:
diff changeset
   939
   * @return a <code>SourceLocator</code> value or null if no location
7f561c08de6b Initial load
duke
parents:
diff changeset
   940
   * is available
7f561c08de6b Initial load
duke
parents:
diff changeset
   941
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   942
  public SourceLocator getSourceLocatorFor(int node);
7f561c08de6b Initial load
duke
parents:
diff changeset
   943
7f561c08de6b Initial load
duke
parents:
diff changeset
   944
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   945
   * As the DTM is registered with the DTMManager, this method
7f561c08de6b Initial load
duke
parents:
diff changeset
   946
   * will be called. This will give the DTM implementation a
7f561c08de6b Initial load
duke
parents:
diff changeset
   947
   * chance to initialize any subsystems that are required to
7f561c08de6b Initial load
duke
parents:
diff changeset
   948
   * build the DTM
7f561c08de6b Initial load
duke
parents:
diff changeset
   949
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   950
  public void documentRegistration();
7f561c08de6b Initial load
duke
parents:
diff changeset
   951
7f561c08de6b Initial load
duke
parents:
diff changeset
   952
  /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   953
   * As documents are released from the DTMManager, the DTM implementation
7f561c08de6b Initial load
duke
parents:
diff changeset
   954
   * will be notified of the event. This will allow the DTM implementation
7f561c08de6b Initial load
duke
parents:
diff changeset
   955
   * to shutdown any subsystem activity that may of been assoiated with
7f561c08de6b Initial load
duke
parents:
diff changeset
   956
   * the active DTM Implementation.
7f561c08de6b Initial load
duke
parents:
diff changeset
   957
   */
7f561c08de6b Initial load
duke
parents:
diff changeset
   958
7f561c08de6b Initial load
duke
parents:
diff changeset
   959
   public void documentRelease();
7f561c08de6b Initial load
duke
parents:
diff changeset
   960
7f561c08de6b Initial load
duke
parents:
diff changeset
   961
   /**
7f561c08de6b Initial load
duke
parents:
diff changeset
   962
    * Migrate a DTM built with an old DTMManager to a new DTMManager.
7f561c08de6b Initial load
duke
parents:
diff changeset
   963
    * After the migration, the new DTMManager will treat the DTM as
7f561c08de6b Initial load
duke
parents:
diff changeset
   964
    * one that is built by itself.
7f561c08de6b Initial load
duke
parents:
diff changeset
   965
    * This is used to support DTM sharing between multiple transformations.
7f561c08de6b Initial load
duke
parents:
diff changeset
   966
    * @param manager the DTMManager
7f561c08de6b Initial load
duke
parents:
diff changeset
   967
    */
7f561c08de6b Initial load
duke
parents:
diff changeset
   968
   public void migrateTo(DTMManager manager);
7f561c08de6b Initial load
duke
parents:
diff changeset
   969
}