com.sun.org.apache.xerces.internal.xni.XMLDocumentHandler Java Examples
The following examples show how to use
com.sun.org.apache.xerces.internal.xni.XMLDocumentHandler.
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: XMLNSDocumentScannerImpl.java From TencentKona-8 with GNU General Public License v2.0 | 6 votes |
/** * Re-configures pipeline by removing the DTD validator * if no DTD grammar exists. If no validator exists in the * pipeline or there is no DTD grammar, namespace binding * is performed by the scanner in the enclosing class. */ private void reconfigurePipeline() { //fDTDValidator will be null in Stax mode if (fNamespaces && fDTDValidator == null) { fBindNamespaces = true; } else if (fNamespaces && !fDTDValidator.hasGrammar() ) { fBindNamespaces = true; fPerformValidation = fDTDValidator.validate(); // re-configure pipeline by removing DTDValidator XMLDocumentSource source = fDTDValidator.getDocumentSource(); XMLDocumentHandler handler = fDTDValidator.getDocumentHandler(); source.setDocumentHandler(handler); if (handler != null) handler.setDocumentSource(source); fDTDValidator.setDocumentSource(null); fDTDValidator.setDocumentHandler(null); } }
Example #2
Source File: XML11NSDocumentScannerImpl.java From jdk1.8-source-analysis with Apache License 2.0 | 6 votes |
/** * Re-configures pipeline by removing the DTD validator * if no DTD grammar exists. If no validator exists in the * pipeline or there is no DTD grammar, namespace binding * is performed by the scanner in the enclosing class. */ private void reconfigurePipeline() { if (fDTDValidator == null) { fBindNamespaces = true; } else if (!fDTDValidator.hasGrammar()) { fBindNamespaces = true; fPerformValidation = fDTDValidator.validate(); // re-configure pipeline XMLDocumentSource source = fDTDValidator.getDocumentSource(); XMLDocumentHandler handler = fDTDValidator.getDocumentHandler(); source.setDocumentHandler(handler); if (handler != null) handler.setDocumentSource(source); fDTDValidator.setDocumentSource(null); fDTDValidator.setDocumentHandler(null); } }
Example #3
Source File: XMLNSDocumentScannerImpl.java From jdk1.8-source-analysis with Apache License 2.0 | 6 votes |
/** * Re-configures pipeline by removing the DTD validator * if no DTD grammar exists. If no validator exists in the * pipeline or there is no DTD grammar, namespace binding * is performed by the scanner in the enclosing class. */ private void reconfigurePipeline() { //fDTDValidator will be null in Stax mode if (fNamespaces && fDTDValidator == null) { fBindNamespaces = true; } else if (fNamespaces && !fDTDValidator.hasGrammar() ) { fBindNamespaces = true; fPerformValidation = fDTDValidator.validate(); // re-configure pipeline by removing DTDValidator XMLDocumentSource source = fDTDValidator.getDocumentSource(); XMLDocumentHandler handler = fDTDValidator.getDocumentHandler(); source.setDocumentHandler(handler); if (handler != null) handler.setDocumentSource(source); fDTDValidator.setDocumentSource(null); fDTDValidator.setDocumentHandler(null); } }
Example #4
Source File: XML11NSDocumentScannerImpl.java From jdk8u60 with GNU General Public License v2.0 | 6 votes |
/** * Re-configures pipeline by removing the DTD validator * if no DTD grammar exists. If no validator exists in the * pipeline or there is no DTD grammar, namespace binding * is performed by the scanner in the enclosing class. */ private void reconfigurePipeline() { if (fDTDValidator == null) { fBindNamespaces = true; } else if (!fDTDValidator.hasGrammar()) { fBindNamespaces = true; fPerformValidation = fDTDValidator.validate(); // re-configure pipeline XMLDocumentSource source = fDTDValidator.getDocumentSource(); XMLDocumentHandler handler = fDTDValidator.getDocumentHandler(); source.setDocumentHandler(handler); if (handler != null) handler.setDocumentSource(source); fDTDValidator.setDocumentSource(null); fDTDValidator.setDocumentHandler(null); } }
Example #5
Source File: XML11NSDocumentScannerImpl.java From JDKSourceCode1.8 with MIT License | 6 votes |
/** * Re-configures pipeline by removing the DTD validator * if no DTD grammar exists. If no validator exists in the * pipeline or there is no DTD grammar, namespace binding * is performed by the scanner in the enclosing class. */ private void reconfigurePipeline() { if (fDTDValidator == null) { fBindNamespaces = true; } else if (!fDTDValidator.hasGrammar()) { fBindNamespaces = true; fPerformValidation = fDTDValidator.validate(); // re-configure pipeline XMLDocumentSource source = fDTDValidator.getDocumentSource(); XMLDocumentHandler handler = fDTDValidator.getDocumentHandler(); source.setDocumentHandler(handler); if (handler != null) handler.setDocumentSource(source); fDTDValidator.setDocumentSource(null); fDTDValidator.setDocumentHandler(null); } }
Example #6
Source File: XML11DTDConfiguration.java From JDKSourceCode1.8 with MIT License | 5 votes |
/** * Sets the document handler on the last component in the pipeline * to receive information about the document. * * @param documentHandler The document handler. */ public void setDocumentHandler(XMLDocumentHandler documentHandler) { fDocumentHandler = documentHandler; if (fLastComponent != null) { fLastComponent.setDocumentHandler(fDocumentHandler); if (fDocumentHandler !=null){ fDocumentHandler.setDocumentSource(fLastComponent); } } }
Example #7
Source File: BasicParserConfiguration.java From TencentKona-8 with GNU General Public License v2.0 | 5 votes |
/** * Sets the document handler on the last component in the pipeline * to receive information about the document. * * @param documentHandler The document handler. */ public void setDocumentHandler(XMLDocumentHandler documentHandler) { fDocumentHandler = documentHandler; if (fLastComponent != null) { fLastComponent.setDocumentHandler(fDocumentHandler); if (fDocumentHandler !=null){ fDocumentHandler.setDocumentSource(fLastComponent); } } }
Example #8
Source File: XMLSchemaValidator.java From JDKSourceCode1.8 with MIT License | 5 votes |
/** Sets the document handler to receive information about the document. */ public void setDocumentHandler(XMLDocumentHandler documentHandler) { fDocumentHandler = documentHandler; // Init reportWhitespace for this handler if (documentHandler instanceof XMLParser) { try { reportWhitespace = ((XMLParser) documentHandler).getFeature(REPORT_WHITESPACE); } catch (Exception e) { reportWhitespace = false; } } }
Example #9
Source File: XML11Configuration.java From JDKSourceCode1.8 with MIT License | 5 votes |
/** * Sets the document handler on the last component in the pipeline * to receive information about the document. * * @param documentHandler The document handler. */ public void setDocumentHandler(XMLDocumentHandler documentHandler) { fDocumentHandler = documentHandler; if (fLastComponent != null) { fLastComponent.setDocumentHandler(fDocumentHandler); if (fDocumentHandler !=null){ fDocumentHandler.setDocumentSource(fLastComponent); } } }
Example #10
Source File: BasicParserConfiguration.java From jdk8u60 with GNU General Public License v2.0 | 5 votes |
/** * Sets the document handler on the last component in the pipeline * to receive information about the document. * * @param documentHandler The document handler. */ public void setDocumentHandler(XMLDocumentHandler documentHandler) { fDocumentHandler = documentHandler; if (fLastComponent != null) { fLastComponent.setDocumentHandler(fDocumentHandler); if (fDocumentHandler !=null){ fDocumentHandler.setDocumentSource(fLastComponent); } } }
Example #11
Source File: XML11NonValidatingConfiguration.java From jdk8u60 with GNU General Public License v2.0 | 5 votes |
/** * Sets the document handler on the last component in the pipeline * to receive information about the document. * * @param documentHandler The document handler. */ public void setDocumentHandler(XMLDocumentHandler documentHandler) { fDocumentHandler = documentHandler; if (fLastComponent != null) { fLastComponent.setDocumentHandler(fDocumentHandler); if (fDocumentHandler !=null){ fDocumentHandler.setDocumentSource(fLastComponent); } } }
Example #12
Source File: XML11DTDConfiguration.java From openjdk-jdk8u with GNU General Public License v2.0 | 5 votes |
/** * Sets the document handler on the last component in the pipeline * to receive information about the document. * * @param documentHandler The document handler. */ public void setDocumentHandler(XMLDocumentHandler documentHandler) { fDocumentHandler = documentHandler; if (fLastComponent != null) { fLastComponent.setDocumentHandler(fDocumentHandler); if (fDocumentHandler !=null){ fDocumentHandler.setDocumentSource(fLastComponent); } } }
Example #13
Source File: BasicParserConfiguration.java From jdk1.8-source-analysis with Apache License 2.0 | 5 votes |
/** * Sets the document handler on the last component in the pipeline * to receive information about the document. * * @param documentHandler The document handler. */ public void setDocumentHandler(XMLDocumentHandler documentHandler) { fDocumentHandler = documentHandler; if (fLastComponent != null) { fLastComponent.setDocumentHandler(fDocumentHandler); if (fDocumentHandler !=null){ fDocumentHandler.setDocumentSource(fLastComponent); } } }
Example #14
Source File: XMLSchemaValidator.java From TencentKona-8 with GNU General Public License v2.0 | 5 votes |
/** Sets the document handler to receive information about the document. */ public void setDocumentHandler(XMLDocumentHandler documentHandler) { fDocumentHandler = documentHandler; // Init reportWhitespace for this handler if (documentHandler instanceof XMLParser) { try { reportWhitespace = ((XMLParser) documentHandler).getFeature(REPORT_WHITESPACE); } catch (Exception e) { reportWhitespace = false; } } }
Example #15
Source File: XML11Configuration.java From openjdk-jdk8u with GNU General Public License v2.0 | 5 votes |
/** * Sets the document handler on the last component in the pipeline * to receive information about the document. * * @param documentHandler The document handler. */ public void setDocumentHandler(XMLDocumentHandler documentHandler) { fDocumentHandler = documentHandler; if (fLastComponent != null) { fLastComponent.setDocumentHandler(fDocumentHandler); if (fDocumentHandler !=null){ fDocumentHandler.setDocumentSource(fLastComponent); } } }
Example #16
Source File: XIncludeParserConfiguration.java From JDKSourceCode1.8 with MIT License | 5 votes |
protected void configureXML11Pipeline() { super.configureXML11Pipeline(); // configure XML 1.1. DTD pipeline fXML11DTDScanner.setDTDHandler(fXML11DTDProcessor); fXML11DTDProcessor.setDTDSource(fXML11DTDScanner); fXML11DTDProcessor.setDTDHandler(fXIncludeHandler); fXIncludeHandler.setDTDSource(fXML11DTDProcessor); fXIncludeHandler.setDTDHandler(fDTDHandler); if (fDTDHandler != null) { fDTDHandler.setDTDSource(fXIncludeHandler); } // configure XML document pipeline: insert after DTDValidator and // before XML Schema validator XMLDocumentSource prev = null; if (fFeatures.get(XMLSCHEMA_VALIDATION) == Boolean.TRUE) { // we don't have to worry about fSchemaValidator being null, since // super.configurePipeline() instantiated it if the feature was set prev = fSchemaValidator.getDocumentSource(); } // Otherwise, insert after the last component in the pipeline else { prev = fLastComponent; fLastComponent = fXIncludeHandler; } XMLDocumentHandler next = prev.getDocumentHandler(); prev.setDocumentHandler(fXIncludeHandler); fXIncludeHandler.setDocumentSource(prev); if (next != null) { fXIncludeHandler.setDocumentHandler(next); next.setDocumentSource(fXIncludeHandler); } }
Example #17
Source File: TeeXMLDocumentFilterImpl.java From jdk8u60 with GNU General Public License v2.0 | 4 votes |
public void setDocumentHandler(XMLDocumentHandler handler) { next = handler; }
Example #18
Source File: SAX2XNI.java From TencentKona-8 with GNU General Public License v2.0 | 4 votes |
public SAX2XNI( XMLDocumentHandler core ) { this.fCore = core; }
Example #19
Source File: XMLNamespaceBinder.java From jdk8u60 with GNU General Public License v2.0 | 4 votes |
/** Sets the document handler to receive information about the document. */ public void setDocumentHandler(XMLDocumentHandler documentHandler) { fDocumentHandler = documentHandler; }
Example #20
Source File: XMLDTDValidator.java From TencentKona-8 with GNU General Public License v2.0 | 4 votes |
/** Returns the document handler */ public XMLDocumentHandler getDocumentHandler() { return fDocumentHandler; }
Example #21
Source File: BasicParserConfiguration.java From TencentKona-8 with GNU General Public License v2.0 | 4 votes |
/** Returns the registered document handler. */ public XMLDocumentHandler getDocumentHandler() { return fDocumentHandler; }
Example #22
Source File: XMLParserConfiguration.java From openjdk-jdk8u with GNU General Public License v2.0 | 4 votes |
/** Returns the registered document handler. */ public XMLDocumentHandler getDocumentHandler();
Example #23
Source File: JAXPValidatorComponent.java From JDKSourceCode1.8 with MIT License | 4 votes |
/** * Get the handler to which we should send events. */ private XMLDocumentHandler handler() { return JAXPValidatorComponent.this.getDocumentHandler(); }
Example #24
Source File: XIncludeHandler.java From openjdk-jdk8u with GNU General Public License v2.0 | 4 votes |
@Override public void setDocumentHandler(XMLDocumentHandler handler) { fDocumentHandler = handler; }
Example #25
Source File: XMLDocumentSource.java From TencentKona-8 with GNU General Public License v2.0 | 4 votes |
/** Sets the document handler. */ public void setDocumentHandler(XMLDocumentHandler handler);
Example #26
Source File: XMLDocumentFilterImpl.java From JDKSourceCode1.8 with MIT License | 4 votes |
public XMLDocumentHandler getDocumentHandler() { return next; }
Example #27
Source File: XML11NonValidatingConfiguration.java From TencentKona-8 with GNU General Public License v2.0 | 4 votes |
/** Returns the registered document handler. */ public XMLDocumentHandler getDocumentHandler() { return fDocumentHandler; }
Example #28
Source File: XPointerElementHandler.java From jdk1.8-source-analysis with Apache License 2.0 | 4 votes |
public void setDocumentHandler(XMLDocumentHandler handler) { fDocumentHandler = handler; }
Example #29
Source File: XMLNamespaceBinder.java From openjdk-jdk8u with GNU General Public License v2.0 | 4 votes |
/** Returns the document handler */ public XMLDocumentHandler getDocumentHandler() { return fDocumentHandler; }
Example #30
Source File: XPointerParserConfiguration.java From JDKSourceCode1.8 with MIT License | 4 votes |
/** Configures the pipeline. */ protected void configurePipeline() { super.configurePipeline(); //configure DTD pipeline fDTDScanner.setDTDHandler(fDTDProcessor); fDTDProcessor.setDTDSource(fDTDScanner); fDTDProcessor.setDTDHandler(fXIncludeHandler); fXIncludeHandler.setDTDSource(fDTDProcessor); fXIncludeHandler.setDTDHandler(fXPointerHandler); fXPointerHandler.setDTDSource(fXIncludeHandler); fXPointerHandler.setDTDHandler(fDTDHandler); if (fDTDHandler != null) { fDTDHandler.setDTDSource(fXPointerHandler); } // configure XML document pipeline: insert after DTDValidator and // before XML Schema validator XMLDocumentSource prev = null; if (fFeatures.get(XMLSCHEMA_VALIDATION) == Boolean.TRUE) { // we don't have to worry about fSchemaValidator being null, since // super.configurePipeline() instantiated it if the feature was set prev = fSchemaValidator.getDocumentSource(); } // Otherwise, insert after the last component in the pipeline else { prev = fLastComponent; fLastComponent = fXPointerHandler; } XMLDocumentHandler next = prev.getDocumentHandler(); prev.setDocumentHandler(fXIncludeHandler); fXIncludeHandler.setDocumentSource(prev); if (next != null) { fXIncludeHandler.setDocumentHandler(next); next.setDocumentSource(fXIncludeHandler); } fXIncludeHandler.setDocumentHandler(fXPointerHandler); fXPointerHandler.setDocumentSource(fXIncludeHandler); }