Examples of WalkingDOMVisitorStub


Examples of com.volantis.mcs.dom.WalkingDOMVisitorStub

        final OutputStyledElementList outputElementList =
                new OutputStyledElementList();

        // iterate over the dom, extracting all the elements into a list
        final OutputStylesFactory factory = new OutputStylesFactory();
        WalkingDOMVisitor visitor = new WalkingDOMVisitorStub() {
            public void visit(Element element) {
                OutputStyles outputStyles = null;
                Styles styles = element.getStyles();
                if (styles != null) {
                    outputStyles = factory.create(element.getName(), styles);
View Full Code Here

Examples of com.volantis.mcs.dom.WalkingDOMVisitorStub

        final StringBuffer altTextBuffer = new StringBuffer();

        if (contentBuffer instanceof DOMOutputBuffer) {
            DOMOutputBuffer domBuffer = (DOMOutputBuffer)contentBuffer;
            Element root = domBuffer.getRoot();
            WalkingDOMVisitor visitor = new WalkingDOMVisitorStub() {

                // Javadoc inherited.
                public void visit(Text text) {
                    if (text.getLength() > 0 && !text.isWhitespace()) {
                        altTextBuffer.append(
View Full Code Here

Examples of com.volantis.mcs.dom.WalkingDOMVisitorStub

        DocumentStyler styler = new DocumentStyler(stylingEngine,
                XDIMESchemata.CDM_NAMESPACE);
        styler.style(document);

        // Make sure that every element has styles set on it.
        DOMWalker walker = new DOMWalker(new WalkingDOMVisitorStub() {
            // Javadoc inherited.
            public void visit(Element element) {
                if (element.getStyles() == null) {
                    throw new IllegalArgumentException(
                            "element " + element.getName() + " has no styles");
View Full Code Here

Examples of com.volantis.mcs.dom.WalkingDOMVisitorStub

            // field, but with the class reference declared final, as
            // illustrated above.

            final boolean [] result = new boolean[] { false };

            WalkingDOMVisitor visitor = new WalkingDOMVisitorStub() {

                // Javadoc inherited.
                public void visit(Text text) {
                    // Would be nice to stop visiting all the other nodes in
                    // the hierarchy, but we can't.
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.