Package org.apache.cocoon.pipeline

Examples of org.apache.cocoon.pipeline.ProcessingException


    public void execute() {
        try {
            this.saxBeanWriter.write(this.bean);
        } catch (IOException e) {
            throw new ProcessingException("Fatal protocol violation", e);
        } catch (SAXException e) {
            throw new ProcessingException("Fatal XML error", e);
        } catch (IntrospectionException e) {
            throw new ProcessingException("Impossible to analyze input bean", e);
        }
    }
View Full Code Here


                writer.flush();
            } finally {
                IOUtils.closeQuietly(inputStream);
            }
        } catch (IOException e) {
            throw new ProcessingException("Failed to produce result.", e);
        }
    }
View Full Code Here

            Fop fop = FOP_FACTORY.newFop(this.outputFormat, outputStream);
            ContentHandler fopContentHandler = fop.getDefaultHandler();

            this.setContentHandler(fopContentHandler);
        } catch (FOPException e) {
            throw new ProcessingException("Impossible to initialize FOPSerializer", e);
        }
    }
View Full Code Here

                String location = response.encodeRedirectURL(this.uri);
                response.sendRedirect(location);
            }
        } catch (IOException e) {
            this.logger.error("Can't redirect to " + this.uri, e);
            throw new ProcessingException(e);
        }
    }
View Full Code Here

        if (this.urlConnection == null) {
            try {
                this.urlConnection = new URL(this.uri).openConnection();

            } catch (IOException e) {
                throw new ProcessingException("Can't connect to the URI " + this.uri, e);
            }
        }

        return this.urlConnection;
    }
View Full Code Here

                this.logger.debug("Including source: " + source);
            }

            return source;
        } catch (MalformedURLException e) {
            throw new ProcessingException(("Can't parse URL " + sourceAtt), e);
        }
    }
View Full Code Here

        try {
            XMLUtils.toOutputStream(this.getUrlConnection().getOutputStream(), saxBuffer);
            XMLUtils.toSax(this.getUrlConnection(), this.getSAXConsumer());
        } catch (IOException e) {
            throw new ProcessingException("Can't stream SaxBuffer into the output stream of the URL "
                    + this.getUrlConnection().getURL());
        }
    }
View Full Code Here

    private URLConnection getUrlConnection() {
        if (this.servletConnection == null) {
            try {
                this.servletConnection = this.service.openConnection();
            } catch (IOException e) {
                throw new ProcessingException("Can't use connected servlet service: " + this.service, e);
            }
        }

        return this.servletConnection;
    }
View Full Code Here

    @Override
    public void setConfiguration(Map<String, ? extends Object> configuration) {
        try {
            this.service = new URL((String) configuration.get("service"));
        } catch (MalformedURLException e) {
            throw new ProcessingException(("Can't create an URL for " + configuration.get("service") + "."), e);
        }
    }
View Full Code Here

            transformerHandler.startDocument();
            saxBuffer.toSAX(new EmbeddedSAXPipe(transformerHandler));
            transformerHandler.endDocument();
        } catch (Exception e) {
            throw new ProcessingException("Can't stream the provided SaxBuffer.", e);
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.cocoon.pipeline.ProcessingException

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.