Top Description Fields Constructors Methods
org.apache.tomcat.util.descriptor

public Class DigesterFactory

extends Object
Class Inheritance
Imports
java.net.URL, java.util.Collections, .HashMap, .Map, jakarta.servlet.ServletContext, org.apache.juli.logging.Log, .LogFactory, org.apache.tomcat.util.digester.Digester, .RuleSet, org.apache.tomcat.util.res.StringManager, org.xml.sax.ext.EntityResolver2

Wrapper class around the Digester that hide Digester's initialization details.

Field Summary

Modifier and TypeField and Description
private static final Class<?>
private static final Class<ServletContext>
public static final Map<String, String>
SERVLET_API_PUBLIC_IDS

Mapping of well-known public IDs used by the Servlet API to the matching local resource.

public static final Map<String, String>
SERVLET_API_SYSTEM_IDS

Mapping of well-known system IDs used by the Servlet API to the matching local resource.

private static final StringManager

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
private static void
add(Map<String, String> ids, String id, String location)

private static void
private static String
public static Digester

Returns:

a new digester
newDigester
(boolean
turn on/off xml validation
xmlValidation
,
boolean
turn on/off namespace validation
xmlNamespaceAware
,
RuleSet
an instance of RuleSet used for parsing the xml.
rule
,
boolean
turn on/off the blocking of external resources
blockExternal
)

Create a Digester parser.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

CLASS_JSP_CONTEXTback to summary
private static final Class<?> CLASS_JSP_CONTEXT
CLASS_SERVLET_CONTEXTback to summary
private static final Class<ServletContext> CLASS_SERVLET_CONTEXT
SERVLET_API_PUBLIC_IDSback to summary
public static final Map<String, String> SERVLET_API_PUBLIC_IDS

Mapping of well-known public IDs used by the Servlet API to the matching local resource.

SERVLET_API_SYSTEM_IDSback to summary
public static final Map<String, String> SERVLET_API_SYSTEM_IDS

Mapping of well-known system IDs used by the Servlet API to the matching local resource.

smback to summary
private static final StringManager sm

Constructor Detail

DigesterFactoryback to summary
public DigesterFactory()

Method Detail

addback to summary
private static void add(Map<String, String> ids, String id, String location)
addSelfback to summary
private static void addSelf(Map<String, String> ids, String id)
locationForback to summary
private static String locationFor(String name)
newDigesterback to summary
public static Digester newDigester(boolean xmlValidation, boolean xmlNamespaceAware, RuleSet rule, boolean blockExternal)

Create a Digester parser.

Parameters
xmlValidation:boolean

turn on/off xml validation

xmlNamespaceAware:boolean

turn on/off namespace validation

rule:RuleSet

an instance of RuleSet used for parsing the xml.

blockExternal:boolean

turn on/off the blocking of external resources

Returns:Digester

a new digester