Examples of XMLConsumer


Examples of org.apache.cocoon.xml.XMLConsumer

        }
        if (this.exception != null) {
            throw this.exception;
        }
        try {
            XMLConsumer consumer;
            if (contentHandler instanceof XMLConsumer) {
                consumer = (XMLConsumer)contentHandler;
            } else if (contentHandler instanceof LexicalHandler) {
                consumer = new ContentHandlerWrapper(contentHandler, (LexicalHandler)contentHandler);
            } else {
View Full Code Here

Examples of org.apache.cocoon.xml.XMLConsumer

        }
        if (this.exception != null) {
            throw this.exception;
        }
        try {
            XMLConsumer consumer;
            if (contentHandler instanceof XMLConsumer) {
                consumer = (XMLConsumer)contentHandler;
            } else if (contentHandler instanceof LexicalHandler) {
                consumer = new ContentHandlerWrapper(contentHandler, (LexicalHandler)contentHandler);
            } else {
View Full Code Here

Examples of org.apache.cocoon.xml.XMLConsumer

    private void connectPipeline(Environment   environment,
                                 ArrayList     usedTransformers,
                                 XMLSerializer xmlSerializer)
    throws ProcessingException {
        XMLProducer prev = this.producer;
        XMLConsumer next;

        boolean configuredSAXConnector = this.manager.hasComponent(SAXConnector.ROLE);

        try {
            int cacheableTransformerCount = this.firstNotCacheableTransformerIndex;
View Full Code Here

Examples of org.apache.cocoon.xml.XMLConsumer

    /** Connect the pipeline.
     */
    protected void connectPipeline(Environment environment) throws ProcessingException {
        XMLProducer prev = (XMLProducer)this.generator;
        XMLConsumer next;

        try {
            Iterator itt = this.transformers.iterator();
            while ( itt.hasNext() ) {
                if (this.configuredSAXConnector) {
View Full Code Here

Examples of org.apache.cocoon.xml.XMLConsumer

            this.setContentHandler(originalContentHandler);
            this.setLexicalHandler(originalLexicalHandler);
            this.originalLexicalHandler = null;
            this.originalContentHandler = null;
        } else {
            XMLConsumer next = (XMLConsumer)recorderStack.peek();
            this.setContentHandler(next);
            this.setLexicalHandler(next);
        }
        return recorder;
    }
View Full Code Here

Examples of org.apache.cocoon.xml.XMLConsumer

    public void startTextRecording()
    throws SAXException {
        if (this.getLogger().isDebugEnabled() == true) {
            this.getLogger().debug("BEGIN startTextRecording");
        }
        XMLConsumer recorder = new TextRecorder();
        this.addRecorder(recorder);

        this.sendStartPrefixMapping();

        if (this.getLogger().isDebugEnabled() == true) {
View Full Code Here

Examples of org.apache.cocoon.xml.XMLConsumer

    public void startParametersRecording()
    throws SAXException {
        if (this.getLogger().isDebugEnabled() == true) {
            this.getLogger().debug("BEGIN startParametersRecording");
        }
        XMLConsumer recorder = new ParametersRecorder();
        this.addRecorder(recorder);

        this.sendStartPrefixMapping();

        if (this.getLogger().isDebugEnabled() == true) {
View Full Code Here

Examples of org.apache.cocoon.xml.XMLConsumer

            } else {

                compiler = (XMLSerializer)this.manager.lookup(XMLSerializer.ROLE);
                compiler.startDocument();

                XMLConsumer nextConsumer = compiler;
                NodeList transformations = XMLUtil.selectNodeList(sunletConf,
                                                        "transformation/stylesheet");
                Transformer xslT = null;
                ArrayList transformers = new ArrayList();
                ComponentSelector selector = null;
                Request request = ObjectModelHelper.getRequest(this.objectModel);

                try {
                    if (transformations != null && transformations.getLength() > 0) {
                        selector = (ComponentSelector) this.manager.lookup(Transformer.ROLE + "Selector");
                        nextConsumer = new IncludeXMLConsumer(nextConsumer);
                        for(int k = transformations.getLength()-1; k >=0; k--) {
                            xslT = (Transformer)selector.select("xslt");
                            transformers.add(xslT);
                            xslT.setup(resolver,
                                       objectModel,
                                       XMLUtil.getValueOfNode(transformations.item(k)),
                                       new Parameters());
                            xslT.setConsumer(nextConsumer);
                            nextConsumer = xslT;
                        }
                        nextConsumer.startDocument();
                    }
                    switch (resource.getResourceType()) {
                        case ResourceConnector.RESOURCE_TYPE_CLASS: {
                             Sunlet theSunlet;
                             try {
View Full Code Here

Examples of org.apache.cocoon.xml.XMLConsumer

    private void connectPipeline(Environment   environment,
                                 ArrayList     usedTransformers,
                                 XMLSerializer xmlSerializer)
    throws ProcessingException {
        XMLProducer prev = this.producer;
        XMLConsumer next;

        try {
            int cacheableTransformerCount = this.firstNotCacheableTransformerIndex;

            Iterator itt = usedTransformers.iterator();
View Full Code Here

Examples of org.apache.cocoon.xml.XMLConsumer

        }
        try {
            if (this.redirectSource != null) {
                SourceUtil.parse(this.manager, this.redirectSource, contentHandler);
            } else {
              XMLConsumer consumer;
              if (contentHandler instanceof XMLConsumer) {
                  consumer = (XMLConsumer)contentHandler;
              } else if (contentHandler instanceof LexicalHandler) {
                  consumer = new ContentHandlerWrapper(contentHandler, (LexicalHandler)contentHandler);
              } else {
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.