1 16 17 22 23 24 package org.apache.xerces.dom; 25 26 37 public final class DeferredAttrNSImpl 38 extends AttrNSImpl 39 implements DeferredNode { 40 41 45 46 static final long serialVersionUID = 6074924934945957154L; 47 48 52 53 protected transient int fNodeIndex; 54 55 59 63 DeferredAttrNSImpl(DeferredDocumentImpl ownerDocument, int nodeIndex) { 64 super(ownerDocument, null); 65 66 fNodeIndex = nodeIndex; 67 needsSyncData(true); 68 needsSyncChildren(true); 69 70 } 72 76 77 public int getNodeIndex() { 78 return fNodeIndex; 79 } 80 81 85 86 protected void synchronizeData() { 87 88 needsSyncData(false); 90 91 DeferredDocumentImpl ownerDocument = 93 (DeferredDocumentImpl) ownerDocument(); 94 name = ownerDocument.getNodeName(fNodeIndex); 95 96 int index = name.indexOf(':'); 98 if (index < 0) { 99 localName = name; 100 } 101 else { 102 localName = name.substring(index + 1); 103 } 104 105 int extra = ownerDocument.getNodeExtra(fNodeIndex); 106 isSpecified((extra & SPECIFIED) != 0); 107 isIdAttribute((extra & ID) != 0); 108 109 namespaceURI = ownerDocument.getNodeURI(fNodeIndex); 110 111 int extraNode = ownerDocument.getLastChild(fNodeIndex); 112 type = ownerDocument.getTypeInfo(extraNode); 113 } 115 121 protected void synchronizeChildren() { 122 DeferredDocumentImpl ownerDocument = 123 (DeferredDocumentImpl) ownerDocument(); 124 ownerDocument.synchronizeChildren(this, fNodeIndex); 125 } 127 } | Popular Tags |