|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.lonniepryor.blues.xml.XmlParser
Responsible for loading XML Schemas and parsing application and module configurations. NOTE: this class is NOT thread-safe and instances may only be used on a single thread at a time.
Constructor Summary | |
|
XmlParser(java.lang.ClassLoader classLoader)
Creates a new XmlParser object. |
protected |
XmlParser(java.lang.ClassLoader classLoader,
javax.xml.parsers.SAXParser schemaValidatingParser)
Creates a new XmlParser object. |
|
XmlParser(java.lang.ClassLoader classLoader,
javax.xml.parsers.SAXParserFactory saxParserFactory)
Creates a new XmlParser object. |
Method Summary | |
static javax.xml.parsers.SAXParser |
createSchemaValidatingParser(java.lang.ClassLoader classLoader,
javax.xml.parsers.SAXParserFactory saxParserFactory)
Creates a JAXP 1.2 parser that validates according to XML Schema. |
ApplicationCfg |
parseApplication(java.lang.String documentPath)
Parses a Blues application configuration file. |
ModuleCfg |
parseModule(java.lang.String documentPath)
Parses a Blues module configuration file. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public XmlParser(java.lang.ClassLoader classLoader)
classLoader
- The class loader to use.public XmlParser(java.lang.ClassLoader classLoader, javax.xml.parsers.SAXParserFactory saxParserFactory)
classLoader
- The class loader to use.saxParserFactory
- FIXMEprotected XmlParser(java.lang.ClassLoader classLoader, javax.xml.parsers.SAXParser schemaValidatingParser)
classLoader
- The class loader to use.schemaValidatingParser
- FIXMEMethod Detail |
public static javax.xml.parsers.SAXParser createSchemaValidatingParser(java.lang.ClassLoader classLoader, javax.xml.parsers.SAXParserFactory saxParserFactory)
classLoader
- The class loader to load schemas from.saxParserFactory
- The sax parser factory to construct a parser with.
public ApplicationCfg parseApplication(java.lang.String documentPath)
documentPath
- The location of the configuration file.
public ModuleCfg parseModule(java.lang.String documentPath)
documentPath
- The location of the configuration file.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |