ChildNode.java revision 286
0N/A * DO NOT REMOVE OR ALTER! 0N/A * Copyright 2000-2002,2004 The Apache Software Foundation. 0N/A * Licensed under the Apache License, Version 2.0 (the "License"); 2362N/A * you may not use this file except in compliance with the License. 0N/A * You may obtain a copy of the License at 0N/A * Unless required by applicable law or agreed to in writing, software 0N/A * distributed under the License is distributed on an "AS IS" BASIS, 0N/A * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 0N/A * See the License for the specific language governing permissions and 0N/A * limitations under the License. 0N/A * ChildNode inherits from NodeImpl and adds the capability of being a child by 0N/A * having references to its previous and next siblings. 0N/A /** Serialization version. */ 0N/A /** Previous sibling. */ 0N/A /** Next sibling. */ 0N/A * No public constructor; only subclasses of Node should be 0N/A * instantiated, and those normally via a Document's factory methods 0N/A * Every Node knows what Document it belongs to. 0N/A }
// <init>(CoreDocumentImpl) 0N/A /** Constructor for serialization. */ 0N/A * Returns a duplicate of a given node. You can consider this a 0N/A * generic "copy constructor" for nodes. The newly returned object should 0N/A * be completely independent of the source object's subtree, so changes 0N/A * in one after the clone has been made will not affect the other. 0N/A * Note: since we never have any children deep is meaningless here, 0N/A * ParentNode overrides this behavior. 0N/A * Example: Cloning a Text node will copy both the node and the text it 0N/A * Example: Cloning something that has children -- Element or Attr, for 0N/A * example -- will _not_ clone those children unless a "deep clone" 0N/A * has been requested. A shallow clone of an Attr node will yield an 0N/A * empty Attr of the same name. 0N/A * NOTE: Clones will always be read/write, even if the node being cloned 0N/A * is read-only, to permit applications using only the DOM API to obtain 0N/A * editable copies of locked portions of the tree. 0N/A // Need to break the association w/ original kids 0N/A }
// cloneNode(boolean):Node 0N/A * Returns the parent node of this node 0N/A // if we have an owner, ownerNode is our parent, otherwise it's 0N/A // our ownerDocument and we don't have a parent 0N/A * same as above but returns internal type 0N/A // if we have an owner, ownerNode is our parent, otherwise it's 0N/A // our ownerDocument and we don't have a parent 0N/A /** The next child of this node's parent, or null if none */ 0N/A /** The previous child of this node's parent, or null if none */ 0N/A // if we are the firstChild, previousSibling actually refers to our 0N/A // parent's lastChild, but we hide that 0N/A * same as above but returns internal type 0N/A // if we are the firstChild, previousSibling actually refers to our 0N/A // parent's lastChild, but we hide that