Methods Summary |
---|
public void | endElement(java.lang.String namespaceURI, java.lang.String localName, java.lang.String qName)
level--;
|
public java.lang.String | getDomainXmlEventListenerClass()
return domainXmlEventListenerClass;
|
public void | parse(java.io.File domainXml, java.io.File dtd)
this.dtd = dtd;
SAXParser saxParser;
SAXParserFactory factory = SAXParserFactory.newInstance();
saxParser = factory.newSAXParser();
saxParser.getXMLReader().setEntityResolver((EntityResolver)this);
saxParser.parse(domainXml,this);
|
public org.xml.sax.InputSource | resolveEntity(java.lang.String publicId, java.lang.String systemId)
InputSource is = null;
try {
is = new InputSource(new java.io.FileInputStream(dtd));
} catch(Exception e) {
throw new SAXException("cannot resolve dtd", e);
}
return is;
|
public void | startElement(java.lang.String namespaceURI, java.lang.String localName, java.lang.String qName, org.xml.sax.Attributes attrs)
level++;
if ( level==2 && PROPERTY.equals(qName)){
if (attrs != null) {
for (int i = 0; i < attrs.getLength(); i++) {
String aName = attrs.getQName(i); // Attr name
String aValue = attrs.getValue(aName);
if ("DomainXmlEventListenerClass".equals(aValue)) {
domainXmlEventListenerClass=attrs.getValue("value");
}
}
}
}
|