Package net.sf.jasperreports.engine.xml
Class JRReportSaxParserFactory
java.lang.Object
net.sf.jasperreports.engine.xml.BaseSaxParserFactory
net.sf.jasperreports.engine.xml.JRReportSaxParserFactory
- All Implemented Interfaces:
JRSaxParserFactory
The default report SAX parser factory.
This factory creates a parser via the default SAX parser factory
(javax.xml.parsers.SAXParserFactory.newInstance()).
JRXMLs are always validated using W3C XML schemas. Reports that refer the JasperReports DTD (which has been deprecated) are validated using an internal XML schema equivalent to the DTD.
To improve performance, XML schemas can be cached when using a Xerces
SAX parser. See BaseSaxParserFactory.PROPERTY_CACHE_SCHEMAS.
- Author:
- Lucian Chirita (lucianc@users.sourceforge.net)
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringWhether to validate the xml report when compiling.Fields inherited from class net.sf.jasperreports.engine.xml.BaseSaxParserFactory
EXCEPTION_MESSAGE_KEY_INCOMPATIBLE_CLASS, EXCEPTION_MESSAGE_KEY_PARSER_CREATION_ERROR, EXCEPTION_MESSAGE_KEY_RESOURCE_NOT_FOUND, jasperReportsContext, PACKAGE_PREFIX_SUN_XERCES, PACKAGE_PREFIX_XERCES, POOL_CLASS_SUN_XERCES, POOL_CLASS_XERCES, PROPERTY_CACHE_SCHEMAS, XERCES_PARSER_PROPERTY_GRAMMAR_POOLFields inherited from interface net.sf.jasperreports.engine.xml.JRSaxParserFactory
PROPERTY_PRINT_PARSER_FACTORY, PROPERTY_REPORT_PARSER_FACTORY, PROPERTY_TEMPLATE_PARSER_FACTORY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected ThreadLocal<org.apache.commons.collections4.map.ReferenceMap<Object,Object>> protected booleanMethods inherited from class net.sf.jasperreports.engine.xml.BaseSaxParserFactory
configureParser, createParser, createSAXParserFactory, enableSchemaCaching, getFactory, getGrammarPoolCacheKey, getResourceURI, setGrammarPoolProperty
-
Field Details
-
COMPILER_XML_VALIDATION
Whether to validate the xml report when compiling.Defaults to
true.- See Also:
-
-
Constructor Details
-
JRReportSaxParserFactory
-
-
Method Details
-
isValidating
protected boolean isValidating()- Specified by:
isValidatingin classBaseSaxParserFactory
-
getSchemaLocations
- Specified by:
getSchemaLocationsin classBaseSaxParserFactory
-
getGrammarPoolCache
protected ThreadLocal<org.apache.commons.collections4.map.ReferenceMap<Object,Object>> getGrammarPoolCache()- Specified by:
getGrammarPoolCachein classBaseSaxParserFactory
-