Examples of XhtmlSaxEmitter


Examples of nu.validator.xml.XhtmlSaxEmitter

     * @param contentHandler
     */
    public XmlMessageEmitter(final ContentHandler contentHandler) {
        this.contentHandler = contentHandler;
        this.emitter = new XmlSaxEmitter(contentHandler);
        this.messageTextHandler = new XhtmlMessageTextHandler(new XhtmlSaxEmitter(contentHandler));
        this.extractHandler = new XmlExtractHandler(emitter);
    }
View Full Code Here

Examples of nu.validator.xml.XhtmlSaxEmitter

        }
        if (!fragments.isEmpty()) {
            ContentHandler ch = emitter.startElaboration();
            if (ch != null) {
                TreeParser treeParser = new TreeParser(ch, null);
                XhtmlSaxEmitter xhtmlSaxEmitter = new XhtmlSaxEmitter(ch);
                xhtmlSaxEmitter.startElement("dl");               
                for (DocumentFragment fragment : fragments) {
                    treeParser.parse(fragment);
                }
                xhtmlSaxEmitter.endElement("dl");
            }
            emitter.endElaboration();
           
        }
    }
View Full Code Here

Examples of nu.validator.xml.XhtmlSaxEmitter

        DocumentFragment dds = spec.contentModelDescription(elt);
        if (dds != null) {
            ContentHandler ch = emitter.startElaboration();
            if (ch != null) {
                TreeParser treeParser = new TreeParser(ch, null);
                XhtmlSaxEmitter xhtmlSaxEmitter = new XhtmlSaxEmitter(ch);
                xhtmlSaxEmitter.startElement("dl");
                emitContentModelDt(xhtmlSaxEmitter, elt);
                treeParser.parse(dds);
                xhtmlSaxEmitter.endElement("dl");
            }
            emitter.endElaboration();
        }
    }
View Full Code Here

Examples of nu.validator.xml.XhtmlSaxEmitter

        DocumentFragment contextDds = spec.contextDescription(child);
        if (contentModelDds != null || contextDds != null) {
            ContentHandler ch = emitter.startElaboration();
            if (ch != null) {
                TreeParser treeParser = new TreeParser(ch, null);
                XhtmlSaxEmitter xhtmlSaxEmitter = new XhtmlSaxEmitter(ch);
                xhtmlSaxEmitter.startElement("dl");
                if (contextDds != null) {
                    emitContextDt(xhtmlSaxEmitter, child);
                    treeParser.parse(contextDds);
                }
                if (contentModelDds != null) {
                    emitContentModelDt(xhtmlSaxEmitter, parent);
                    treeParser.parse(contentModelDds);
                }
                xhtmlSaxEmitter.endElement("dl");
            }
            emitter.endElaboration();
        }
    }
View Full Code Here

Examples of nu.validator.xml.XhtmlSaxEmitter

    private void elaborateElementSpecificAttributes(Name elt, Name attribute)
            throws SAXException {
        if ("input".equals(elt.getLocalName())) {
            ContentHandler ch = emitter.startElaboration();
            if (ch != null) {
                XhtmlSaxEmitter xhtmlSaxEmitter = new XhtmlSaxEmitter(ch);
                elaborateInputAttributes(xhtmlSaxEmitter, elt, attribute);
            }
            emitter.endElaboration();
        } else {
            DocumentFragment dds = spec.elementSpecificAttributesDescription(elt);
            if (dds != null) {
                ContentHandler ch = emitter.startElaboration();
                if (ch != null) {
                    TreeParser treeParser = new TreeParser(ch, null);
                    XhtmlSaxEmitter xhtmlSaxEmitter = new XhtmlSaxEmitter(ch);
                    xhtmlSaxEmitter.startElement("dl");
                    emitElementSpecificAttributesDt(xhtmlSaxEmitter, elt);
                    treeParser.parse(dds);
                    xhtmlSaxEmitter.endElement("dl");
                }
                emitter.endElaboration();
            }
        }
    }
View Full Code Here

Examples of nu.validator.xml.XhtmlSaxEmitter

    private final AttributesImpl attrs = new AttributesImpl();

    public XhtmlOutlineEmitter(final ContentHandler contentHandler,
            final Deque<Section> outline) {
        this.emitter = new XhtmlSaxEmitter(contentHandler);
        this.outline = outline;
    }
View Full Code Here

Examples of nu.validator.xml.XhtmlSaxEmitter

                } else {
                    response.setContentType("application/xhtml+xml");
                    contentHandler =
                            new XmlSerializer(out);
                }
                emitter = new XhtmlSaxEmitter(contentHandler);
                errorHandler = new MessageEmitterAdapter(sourceCode,
                        showSource, imageCollector, lineOffset, false,
                        new XhtmlMessageEmitter(contentHandler));
                PageEmitter.emit(contentHandler, this);
            } else {
View Full Code Here

Examples of nu.validator.xml.XhtmlSaxEmitter

                } else {
                    response.setContentType("application/xhtml+xml");
                    contentHandler =
                            new XmlSerializer(out);
                }
                emitter = new XhtmlSaxEmitter(contentHandler);
                errorHandler = new MessageEmitterAdapter(sourceCode,
                        showSource, imageCollector, lineOffset,
                        new XhtmlMessageEmitter(contentHandler));
                if (W3C_BRANDING) {
                    W3CPageEmitter.emit(contentHandler, this);
View Full Code Here

Examples of nu.validator.xml.XhtmlSaxEmitter

        }
        if (!fragments.isEmpty()) {
            ContentHandler ch = emitter.startElaboration();
            if (ch != null) {
                TreeParser treeParser = new TreeParser(ch, null);
                XhtmlSaxEmitter xhtmlSaxEmitter = new XhtmlSaxEmitter(ch);
                xhtmlSaxEmitter.startElement("dl");               
                for (DocumentFragment fragment : fragments) {
                    treeParser.parse(fragment);
                }
                xhtmlSaxEmitter.endElement("dl");
            }
            emitter.endElaboration();
           
        }
    }
View Full Code Here

Examples of nu.validator.xml.XhtmlSaxEmitter

        DocumentFragment dds = spec.contentModelDescription(elt);
        if (dds != null) {
            ContentHandler ch = emitter.startElaboration();
            if (ch != null) {
                TreeParser treeParser = new TreeParser(ch, null);
                XhtmlSaxEmitter xhtmlSaxEmitter = new XhtmlSaxEmitter(ch);
                xhtmlSaxEmitter.startElement("dl");
                emitContentModelDt(xhtmlSaxEmitter, elt);
                treeParser.parse(dds);
                xhtmlSaxEmitter.endElement("dl");
            }
            emitter.endElaboration();
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.