- Javax.xml.bind classes
- Home
- Binder
- DatatypeConverter
- JAXB
- JAXBContext
- JAXBElement
- JAXBElement.GlobalScope
- JAXBIntrospector
- Marshaller.Listener
- SchemaOutputResolver
- Unmarshaller.Listener
- Javax.xml.bind.util classes
- JAXBResult
- JAXBSource
- ValidationEventCollector
- Javax.xml.parsers classes
- DocumentBuilder
- DocumentBuilderFactory
- SAXParser
- SAXParserFactory
- Javax.xml.soap classes
- AttachmentPart
- MessageFactory
- MimeHeader
- MimeHeaders
- SAAJMetaFactory
- SOAPConnection
- SOAPConnectionFactory
- SOAPFactory
- SOAPMessage
- SOAPPart
- Javax.xml.validation classes
- Schema
- SchemaFactory
- TypeInfoProvider
- Validator
- ValidatorHandler
- Javax.xml.xpath classes
- XPathConstants
- XPathFactory
- Java Useful Resources
- Java - Quick Guide
- Java - Useful Resources
DocumentBuilderFactory setXIncludeAware() Method
Description
The Javax.xml.parsers.DocumentBuilderFactory.setXIncludeAware(boolean state) method sets state of XInclude processing.
If XInclude markup is found in the document instance, should it be processed as specified in XML Inclusions (XInclude) Version 1.0.
XInclude processing defaults to false.
Declaration
Following is the declaration for Javax.xml.parsers.DocumentBuilderFactory.setXIncludeAware() method
public void setXIncludeAware(boolean state)
Parameters
state − Set XInclude processing to true or false
Return Value
This method does not return a value.
Exception
UnsupportedOperationException − When implementation does not override this method.
Example
The following example shows the usage of Javax.xml.parsers.DocumentBuilderFactory.setXIncludeAware() method.
package com.tutorialspoint; import javax.xml.parsers.DocumentBuilderFactory; public class DocumentBuilderFactoryDemo { public static void main(String[] args) { // create a new DocumentBuilderFactory DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); // change this configuration factory.setXIncludeAware(true); // check if factory is XInclude processing System.out.println("" + factory.isXIncludeAware()); } }
If we compile the code and execute it, this will produce the following result −
true
javax_xml_parsers_documentbuilderfactory.htm
Advertisements
To Continue Learning Please Login
Login with Google