Package org.xmlunit.util
Class TransformerFactoryConfigurer.Builder
java.lang.Object
org.xmlunit.util.TransformerFactoryConfigurer.Builder
- Enclosing class:
- TransformerFactoryConfigurer
Builder for a TransformerFactoryConfigurer.
- Since:
- XMLUnit 2.6.0
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds a TransformerFactoryConfigurer.withAttribute
(String key, Object value) Configures the factory with the given attribute, causes an exception inTransformerFactoryConfigurer.configure(javax.xml.transform.TransformerFactory)
if the attribute is not supported.Configures the factory to not load any external DTDs.Configures the factory to not enable extension functions.Configures the factory to not parse any DTDs.withFeature
(String key, boolean value) Configures the factory with the given feature, causes an exception inTransformerFactoryConfigurer.configure(javax.xml.transform.TransformerFactory)
if the feature is not supported.withSafeAttribute
(String key, Object value) Configures the factory with the given attribute if it is supported.withSafeFeature
(String key, boolean value) Configures the factory with the given feature if it is supported.Configures the factory to enable secure processing which disables all external access as well as execution of extension functions.
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
build
Builds a TransformerFactoryConfigurer.- Returns:
- the configurer
-
withAttribute
Configures the factory with the given attribute, causes an exception inTransformerFactoryConfigurer.configure(javax.xml.transform.TransformerFactory)
if the attribute is not supported.- Parameters:
key
- key of the attribute to be setvalue
- value for the attribute to set- Returns:
- this
-
withSafeAttribute
Configures the factory with the given attribute if it is supported.- Parameters:
key
- key of the attribute to be setvalue
- value for the attribute to set- Returns:
- this
-
withFeature
Configures the factory with the given feature, causes an exception inTransformerFactoryConfigurer.configure(javax.xml.transform.TransformerFactory)
if the feature is not supported.- Parameters:
key
- key of the feature to be setvalue
- value for the feature to set- Returns:
- this
-
withSafeFeature
Configures the factory with the given feature if it is supported.- Parameters:
key
- key of the feature to be setvalue
- value for the feature to set- Returns:
- this
-
withDTDLoadingDisabled
Configures the factory to not load any external DTDs.- Returns:
- this
-
withExternalStylesheetLoadingDisabled
Configures the factory to not parse any DTDs.- Returns:
- this
-
withExtensionFunctionsDisabled
Configures the factory to not enable extension functions.- Returns:
- this
- Since:
- XMLUnit 2.10.0
-
withSecureProcessingEnabled
Configures the factory to enable secure processing which disables all external access as well as execution of extension functions.- Returns:
- this
- Since:
- XMLUnit 2.10.0
-