Package org.apache.cocoon.response

Examples of org.apache.cocoon.response.RedirectException


                        // pass the request object to the producer and produce the initial
                        // Document
                        if (PROFILE) profiler.startEvent (requestMarker, producer.getClass ());
                        Document document = producer.getDocument(request);
                        if (PROFILE) profiler.finishEvent (requestMarker, producer.getClass ());
                        if (((HttpServletResponseFacade) response).hasRedirected) throw new RedirectException ();

                        if (LOG) logger.log(this, "Document produced", Logger.DEBUG);

                        // See if disable caching processing instruction exists
                        if (Utils.getFirstPI (document, DISABLE_CACHING_PI, true) != null) {
                            page.setChangeable (UNCACHEABLE);
                        }

                        // pass needed parameters to the processor pipeline
                        Hashtable environment = new Hashtable();
                        environment.put("path", producer.getPath(request));
                        environment.put("browser", browsers.map(agent));
                        environment.put("request", request);
                        environment.put("response", response);
                        if (servletContext != null) environment.put("context", servletContext);

                        // process the document through the document processors
                        for (int processNum = 0; true; processNum++) {
                            Processor processor = processors.getProcessor(document);
                            if (processor == null) break;
                            String processDesc = processor.getClass ().getName () + "-" + processNum;
                            if (PROFILE) profiler.startEvent (requestMarker, processDesc);
                            document = processor.process(document, environment);
                            page.setChangeable(processor);
                            if (PROFILE) profiler.finishEvent (requestMarker, processDesc);
                            if (((HttpServletResponseFacade) response).hasRedirected) throw new RedirectException ();
                            if (LOG) logger.log(this, "Document processed", Logger.DEBUG);
                        }

                        // get the right formatter for the page
                        Formatter formatter = formatters.getFormatter(document);
View Full Code Here

TOP

Related Classes of org.apache.cocoon.response.RedirectException

Copyright © 2018 www.massapicom. 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.