1 package com.icl.saxon.jdom; 2 import com.icl.saxon.om.DocumentInfo; 3 import com.icl.saxon.om.NamePool; 4 import com.icl.saxon.om.NodeInfo; 5 import com.icl.saxon.KeyManager; 6 import org.jdom.Document; 7 8 import java.util.Hashtable ; 9 10 11 18 19 public class DocumentWrapper extends NodeWrapper implements DocumentInfo { 20 21 protected Hashtable keyTable = new Hashtable (); 22 protected NamePool namePool; 23 protected String baseURI; 24 25 public DocumentWrapper(Document doc, String baseURI) { 26 super(doc, null, 0); 27 node = doc; 28 nodeType = NodeInfo.ROOT; 29 this.baseURI = baseURI; 30 docWrapper = this; 31 namePool = NamePool.getDefaultNamePool(); 32 } 33 34 37 38 public void setNamePool(NamePool pool) { 39 namePool = pool; 40 } 41 42 45 46 public NamePool getNamePool() { 47 return namePool; 48 } 49 50 55 56 public NodeInfo selectID(String id) { 57 return null; 58 } 59 60 68 69 public Hashtable getKeyIndex(KeyManager keyManager, int fingerprint) { 70 String key = keyManager.hashCode() + "#" + fingerprint; 71 return (Hashtable )keyTable.get(key); 72 } 73 74 81 82 public void setKeyIndex(KeyManager keyManager, int fingerprint, Hashtable index) { 83 String key = keyManager.hashCode() + "#" + fingerprint; 84 keyTable.put(key, index); 85 } 86 87 92 93 public String getUnparsedEntity(String name) { 94 return null; 95 } 96 97 98 } 99 100 | Popular Tags |