|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jboss.cache.config.parsing.XmlParserBase
org.jboss.cache.config.parsing.XmlConfigurationParser
public class XmlConfigurationParser
Reads in XMLconfiguration files and spits out a Configuration object.
By default this class uses a validating parser (configurable).
RootElementBuilder| Field Summary |
|---|
| Fields inherited from class org.jboss.cache.config.parsing.XmlParserBase |
|---|
coreNamespace |
| Constructor Summary | |
|---|---|
XmlConfigurationParser()
Constructs a parser having validation enabled with a ErrorHandler that only logs the parser errors. |
|
XmlConfigurationParser(boolean validating,
ErrorHandler errorHandler)
Same as XmlConfigurationParser(org.xml.sax.ErrorHandler). |
|
XmlConfigurationParser(ErrorHandler errorHandler)
If validation is on (default) one can specify an error handler for handling validation errors. |
|
| Method Summary | |
|---|---|
boolean |
isValidating()
|
boolean |
isValidElementRoot(Element element)
Tests whether the element passed in is a modern (3.0) config element rather than a legacy one. |
Configuration |
parseElement(Element root)
Root should be the jbosscache element in the configuration file. |
Configuration |
parseElementIgnoringRoot(Element root)
|
Configuration |
parseFile(String filename)
Parses an XML file and returns a new configuration. |
Configuration |
parseStream(InputStream configStream)
Similar to parseFile(String), just that it does not create the input stream. |
| Methods inherited from class org.jboss.cache.config.parsing.XmlParserBase |
|---|
assertNotLegacyElement, existsAttribute, getAttributeValue, getBoolean, getInt, getLong, getSingleElement, getSingleElementInCoreNS |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public XmlConfigurationParser(ErrorHandler errorHandler)
public XmlConfigurationParser(boolean validating,
ErrorHandler errorHandler)
XmlConfigurationParser(org.xml.sax.ErrorHandler).
validating - should the underlaying parser disable the validation?public XmlConfigurationParser()
| Method Detail |
|---|
public Configuration parseFile(String filename)
FileLookup is used.
FileLookuppublic Configuration parseStream(InputStream configStream)
parseFile(String), just that it does not create the input stream.
public Configuration parseElement(Element root)
public Configuration parseElementIgnoringRoot(Element root)
public boolean isValidating()
public boolean isValidElementRoot(Element element)
element - element to test
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||