setDOOMRequired(boolean) in a concurrent environment can
lead to unexpected behavior and severe bugs, as shown in
AXIOM-3 and
AXIS2-1570.
Due to the way newDocumentBuilder() is implemented, it is not possible
to get rid of the setDOOMRequired hack without the risk of breaking existing code.
Application code should always use DOMMetaFactory.newDocumentBuilderFactory()
to get an Axiom compatible DocumentBuilderFactory and should not attempt to
override the JVM's default DocumentBuilderFactory with an Axiom compatible
version.
public class DocumentBuilderFactoryImpl extends DocumentBuilderFactory
| Constructor and Description |
|---|
DocumentBuilderFactoryImpl()
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
Object |
getAttribute(String name)
Deprecated.
|
boolean |
getFeature(String name)
Deprecated.
|
Schema |
getSchema()
Deprecated.
|
static boolean |
isDOOMRequired()
Deprecated.
|
DocumentBuilder |
newDocumentBuilder()
Deprecated.
|
static DocumentBuilderFactory |
newInstance()
Deprecated.
|
void |
setAttribute(String name,
Object value)
Deprecated.
|
static void |
setDOOMRequired(boolean isDOOMRequired)
Deprecated.
|
void |
setFeature(String name,
boolean value)
Deprecated.
|
void |
setSchema(Schema schema)
Deprecated.
|
isCoalescing, isExpandEntityReferences, isIgnoringComments, isIgnoringElementContentWhitespace, isNamespaceAware, isValidating, isXIncludeAware, newInstance, setCoalescing, setExpandEntityReferences, setIgnoringComments, setIgnoringElementContentWhitespace, setNamespaceAware, setValidating, setXIncludeAwareprotected Schema schema
public static boolean isDOOMRequired()
public static void setDOOMRequired(boolean isDOOMRequired)
public DocumentBuilder newDocumentBuilder() throws ParserConfigurationException
newDocumentBuilder in class DocumentBuilderFactoryParserConfigurationExceptionpublic Object getAttribute(String name) throws IllegalArgumentException
getAttribute in class DocumentBuilderFactoryIllegalArgumentExceptionpublic void setAttribute(String name, Object value) throws IllegalArgumentException
setAttribute in class DocumentBuilderFactoryIllegalArgumentExceptionpublic static DocumentBuilderFactory newInstance()
public void setFeature(String name, boolean value) throws ParserConfigurationException
setFeature in class DocumentBuilderFactoryParserConfigurationExceptionpublic boolean getFeature(String name) throws ParserConfigurationException
getFeature in class DocumentBuilderFactoryParserConfigurationExceptionpublic void setSchema(Schema schema)
setSchema in class DocumentBuilderFactorypublic Schema getSchema()
getSchema in class DocumentBuilderFactoryCopyright ? The Apache Software Foundation. All Rights Reserved.