Java Code Examples for com.sun.xml.internal.bind.v2.util.XmlFactory#createDocumentBuilderFactory()
The following examples show how to use
com.sun.xml.internal.bind.v2.util.XmlFactory#createDocumentBuilderFactory() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: DomHandlerEx.java From TencentKona-8 with GNU General Public License v2.0 | 6 votes |
ResultImpl() { try { DocumentBuilderFactory factory = XmlFactory.createDocumentBuilderFactory(false); // safe - only used for BI s2d = new SAX2DOMEx(factory); } catch (ParserConfigurationException e) { throw new AssertionError(e); // impossible } XMLFilterImpl f = new XMLFilterImpl() { @Override public void setDocumentLocator(Locator locator) { super.setDocumentLocator(locator); location = new LocatorImpl(locator); } }; f.setContentHandler(s2d); setHandler(f); }
Example 2
Source File: DomHandlerEx.java From openjdk-8 with GNU General Public License v2.0 | 6 votes |
ResultImpl() { try { DocumentBuilderFactory factory = XmlFactory.createDocumentBuilderFactory(false); // safe - only used for BI s2d = new SAX2DOMEx(factory); } catch (ParserConfigurationException e) { throw new AssertionError(e); // impossible } XMLFilterImpl f = new XMLFilterImpl() { @Override public void setDocumentLocator(Locator locator) { super.setDocumentLocator(locator); location = new LocatorImpl(locator); } }; f.setContentHandler(s2d); setHandler(f); }
Example 3
Source File: DomHandlerEx.java From jdk8u60 with GNU General Public License v2.0 | 6 votes |
ResultImpl() { try { DocumentBuilderFactory factory = XmlFactory.createDocumentBuilderFactory(false); // safe - only used for BI s2d = new SAX2DOMEx(factory); } catch (ParserConfigurationException e) { throw new AssertionError(e); // impossible } XMLFilterImpl f = new XMLFilterImpl() { @Override public void setDocumentLocator(Locator locator) { super.setDocumentLocator(locator); location = new LocatorImpl(locator); } }; f.setContentHandler(s2d); setHandler(f); }
Example 4
Source File: DomHandlerEx.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 6 votes |
ResultImpl() { try { DocumentBuilderFactory factory = XmlFactory.createDocumentBuilderFactory(false); // safe - only used for BI s2d = new SAX2DOMEx(factory); } catch (ParserConfigurationException e) { throw new AssertionError(e); // impossible } XMLFilterImpl f = new XMLFilterImpl() { @Override public void setDocumentLocator(Locator locator) { super.setDocumentLocator(locator); location = new LocatorImpl(locator); } }; f.setContentHandler(s2d); setHandler(f); }
Example 5
Source File: JAXBContextImpl.java From openjdk-8-source with GNU General Public License v2.0 | 5 votes |
/** * Creates a new DOM document. */ static Document createDom(boolean disableSecurityProcessing) { synchronized(JAXBContextImpl.class) { if(db==null) { try { DocumentBuilderFactory dbf = XmlFactory.createDocumentBuilderFactory(disableSecurityProcessing); db = dbf.newDocumentBuilder(); } catch (ParserConfigurationException e) { // impossible throw new FactoryConfigurationError(e); } } return db.newDocument(); } }
Example 6
Source File: JAXBContextImpl.java From openjdk-jdk9 with GNU General Public License v2.0 | 5 votes |
/** * Creates a new DOM document. */ static Document createDom(boolean disableSecurityProcessing) { synchronized(JAXBContextImpl.class) { if(db==null) { try { DocumentBuilderFactory dbf = XmlFactory.createDocumentBuilderFactory(disableSecurityProcessing); db = dbf.newDocumentBuilder(); } catch (ParserConfigurationException e) { // impossible throw new FactoryConfigurationError(e); } } return db.newDocument(); } }
Example 7
Source File: DOMForest.java From openjdk-jdk9 with GNU General Public License v2.0 | 5 votes |
public DOMForest( InternalizationLogic logic, Options opt ) { if (opt == null) throw new AssertionError("Options object null"); this.options = opt; try { DocumentBuilderFactory dbf = XmlFactory.createDocumentBuilderFactory(opt.disableXmlSecurity); this.documentBuilder = dbf.newDocumentBuilder(); this.parserFactory = XmlFactory.createParserFactory(opt.disableXmlSecurity); } catch( ParserConfigurationException e ) { throw new AssertionError(e); } this.logic = logic; }
Example 8
Source File: JAXBContextImpl.java From openjdk-8 with GNU General Public License v2.0 | 5 votes |
/** * Creates a new DOM document. */ static Document createDom(boolean disableSecurityProcessing) { synchronized(JAXBContextImpl.class) { if(db==null) { try { DocumentBuilderFactory dbf = XmlFactory.createDocumentBuilderFactory(disableSecurityProcessing); db = dbf.newDocumentBuilder(); } catch (ParserConfigurationException e) { // impossible throw new FactoryConfigurationError(e); } } return db.newDocument(); } }
Example 9
Source File: SAX2DOMEx.java From hottub with GNU General Public License v2.0 | 5 votes |
/** * Creates a fresh empty DOM document and adds nodes under this document. * @deprecated */ public SAX2DOMEx() throws ParserConfigurationException { DocumentBuilderFactory factory = XmlFactory.createDocumentBuilderFactory(false); factory.setValidating(false); document = factory.newDocumentBuilder().newDocument(); node = document; nodeStack.push(document); }
Example 10
Source File: JAXBContextImpl.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 5 votes |
/** * Creates a new DOM document. */ static Document createDom(boolean disableSecurityProcessing) { synchronized(JAXBContextImpl.class) { if(db==null) { try { DocumentBuilderFactory dbf = XmlFactory.createDocumentBuilderFactory(disableSecurityProcessing); db = dbf.newDocumentBuilder(); } catch (ParserConfigurationException e) { // impossible throw new FactoryConfigurationError(e); } } return db.newDocument(); } }
Example 11
Source File: SAX2DOMEx.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 5 votes |
/** * Creates a fresh empty DOM document and adds nodes under this document. * @deprecated */ public SAX2DOMEx() throws ParserConfigurationException { DocumentBuilderFactory factory = XmlFactory.createDocumentBuilderFactory(false); factory.setValidating(false); document = factory.newDocumentBuilder().newDocument(); node = document; nodeStack.push(document); }
Example 12
Source File: DOMForest.java From hottub with GNU General Public License v2.0 | 5 votes |
public DOMForest( InternalizationLogic logic, Options opt ) { if (opt == null) throw new AssertionError("Options object null"); this.options = opt; try { DocumentBuilderFactory dbf = XmlFactory.createDocumentBuilderFactory(opt.disableXmlSecurity); this.documentBuilder = dbf.newDocumentBuilder(); this.parserFactory = XmlFactory.createParserFactory(opt.disableXmlSecurity); } catch( ParserConfigurationException e ) { throw new AssertionError(e); } this.logic = logic; }
Example 13
Source File: SAX2DOMEx.java From TencentKona-8 with GNU General Public License v2.0 | 5 votes |
/** * Creates a fresh empty DOM document and adds nodes under this document. * @deprecated */ public SAX2DOMEx() throws ParserConfigurationException { DocumentBuilderFactory factory = XmlFactory.createDocumentBuilderFactory(false); factory.setValidating(false); document = factory.newDocumentBuilder().newDocument(); node = document; nodeStack.push(document); }
Example 14
Source File: JAXBContextImpl.java From openjdk-jdk8u with GNU General Public License v2.0 | 5 votes |
/** * Creates a new DOM document. */ static Document createDom(boolean disableSecurityProcessing) { synchronized(JAXBContextImpl.class) { if(db==null) { try { DocumentBuilderFactory dbf = XmlFactory.createDocumentBuilderFactory(disableSecurityProcessing); db = dbf.newDocumentBuilder(); } catch (ParserConfigurationException e) { // impossible throw new FactoryConfigurationError(e); } } return db.newDocument(); } }
Example 15
Source File: DOMForest.java From openjdk-8-source with GNU General Public License v2.0 | 5 votes |
public DOMForest( InternalizationLogic logic, Options opt ) { if (opt == null) throw new AssertionError("Options object null"); this.options = opt; try { DocumentBuilderFactory dbf = XmlFactory.createDocumentBuilderFactory(opt.disableXmlSecurity); this.documentBuilder = dbf.newDocumentBuilder(); this.parserFactory = XmlFactory.createParserFactory(opt.disableXmlSecurity); } catch( ParserConfigurationException e ) { throw new AssertionError(e); } this.logic = logic; }
Example 16
Source File: DOMForest.java From jdk8u60 with GNU General Public License v2.0 | 5 votes |
public DOMForest( InternalizationLogic logic, Options opt ) { if (opt == null) throw new AssertionError("Options object null"); this.options = opt; try { DocumentBuilderFactory dbf = XmlFactory.createDocumentBuilderFactory(opt.disableXmlSecurity); this.documentBuilder = dbf.newDocumentBuilder(); this.parserFactory = XmlFactory.createParserFactory(opt.disableXmlSecurity); } catch( ParserConfigurationException e ) { throw new AssertionError(e); } this.logic = logic; }
Example 17
Source File: DOMForest.java From openjdk-8 with GNU General Public License v2.0 | 5 votes |
public DOMForest( InternalizationLogic logic, Options opt ) { if (opt == null) throw new AssertionError("Options object null"); this.options = opt; try { DocumentBuilderFactory dbf = XmlFactory.createDocumentBuilderFactory(opt.disableXmlSecurity); this.documentBuilder = dbf.newDocumentBuilder(); this.parserFactory = XmlFactory.createParserFactory(opt.disableXmlSecurity); } catch( ParserConfigurationException e ) { throw new AssertionError(e); } this.logic = logic; }
Example 18
Source File: SAX2DOMEx.java From jdk8u60 with GNU General Public License v2.0 | 5 votes |
/** * Creates a fresh empty DOM document and adds nodes under this document. * @deprecated */ public SAX2DOMEx() throws ParserConfigurationException { DocumentBuilderFactory factory = XmlFactory.createDocumentBuilderFactory(false); factory.setValidating(false); document = factory.newDocumentBuilder().newDocument(); node = document; nodeStack.push(document); }
Example 19
Source File: DOMForest.java From TencentKona-8 with GNU General Public License v2.0 | 5 votes |
public DOMForest( InternalizationLogic logic, Options opt ) { if (opt == null) throw new AssertionError("Options object null"); this.options = opt; try { DocumentBuilderFactory dbf = XmlFactory.createDocumentBuilderFactory(opt.disableXmlSecurity); this.documentBuilder = dbf.newDocumentBuilder(); this.parserFactory = XmlFactory.createParserFactory(opt.disableXmlSecurity); } catch( ParserConfigurationException e ) { throw new AssertionError(e); } this.logic = logic; }
Example 20
Source File: JAXBContextImpl.java From TencentKona-8 with GNU General Public License v2.0 | 5 votes |
/** * Creates a new DOM document. */ static Document createDom(boolean disableSecurityProcessing) { synchronized(JAXBContextImpl.class) { if(db==null) { try { DocumentBuilderFactory dbf = XmlFactory.createDocumentBuilderFactory(disableSecurityProcessing); db = dbf.newDocumentBuilder(); } catch (ParserConfigurationException e) { // impossible throw new FactoryConfigurationError(e); } } return db.newDocument(); } }