Lines 140-155
Link Here
|
140 |
this(symbolTable, null); |
140 |
this(symbolTable, null); |
141 |
} // <init>(SymbolTable) |
141 |
} // <init>(SymbolTable) |
142 |
|
142 |
|
|
|
143 |
private static XMLParserConfiguration getParserConfig() { // XXX added - jglick |
144 |
Object o = ObjectFactory.createObject( |
145 |
"org.apache.xerces.xni.parser.XMLParserConfiguration", |
146 |
"org.apache.xerces.parsers.XML11Configuration" |
147 |
); |
148 |
if (o instanceof XMLParserConfiguration) { |
149 |
return (XMLParserConfiguration)o; |
150 |
} else { |
151 |
// something is wrong |
152 |
Thread.dumpStack(); |
153 |
System.err.println("Got object: " + o); |
154 |
System.err.println(" class: " + o.getClass().getName()); |
155 |
System.err.println(" loader: " + o.getClass().getClassLoader()); |
156 |
System.err.println(" location: " + o.getClass().getProtectionDomain().getCodeSource().getLocation()); |
157 |
System.err.println(" my loader: " + XMLParserConfiguration.class.getClassLoader()); |
158 |
System.err.println(" location: " + XMLParserConfiguration.class.getProtectionDomain().getCodeSource().getLocation()); |
159 |
return new XML11Configuration(); |
160 |
} |
161 |
} |
162 |
|
143 |
|
163 |
|
144 |
/** |
164 |
/** |
145 |
* Constructs a DOM parser using the specified symbol table and |
165 |
* Constructs a DOM parser using the specified symbol table and |
146 |
* grammar pool. |
166 |
* grammar pool. |
147 |
*/ |
167 |
*/ |
148 |
public DOMParser(SymbolTable symbolTable, XMLGrammarPool grammarPool) { |
168 |
public DOMParser(SymbolTable symbolTable, XMLGrammarPool grammarPool) { |
149 |
super((XMLParserConfiguration)ObjectFactory.createObject( |
169 |
super(getParserConfig()); |
150 |
"org.apache.xerces.xni.parser.XMLParserConfiguration", |
|
|
151 |
"org.apache.xerces.parsers.XML11Configuration" |
152 |
)); |
153 |
|
170 |
|
154 |
// set properties |
171 |
// set properties |
155 |
fConfiguration.addRecognizedProperties(RECOGNIZED_PROPERTIES); |
172 |
fConfiguration.addRecognizedProperties(RECOGNIZED_PROPERTIES); |