You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@cocoon.apache.org by vg...@apache.org on 2007/10/24 04:42:12 UTC
svn commit: r587751 [3/5] - in /cocoon/trunk/core:
cocoon-expression-language/cocoon-expression-language-api/src/main/java/org/apache/cocoon/el/
cocoon-expression-language/cocoon-expression-language-api/src/main/java/org/apache/cocoon/el/objectmodel/
c...
Modified: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/components/source/util/SourceUtil.java
URL: http://svn.apache.org/viewvc/cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/components/source/util/SourceUtil.java?rev=587751&r1=587750&r2=587751&view=diff
==============================================================================
--- cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/components/source/util/SourceUtil.java (original)
+++ cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/components/source/util/SourceUtil.java Tue Oct 23 19:41:36 2007
@@ -1,639 +1,639 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.cocoon.components.source.util;
-
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.io.Reader;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-
-import org.apache.avalon.framework.parameters.Parameters;
-import org.apache.avalon.framework.service.ServiceException;
-import org.apache.avalon.framework.service.ServiceManager;
-import org.apache.cocoon.ProcessingException;
-import org.apache.cocoon.ResourceNotFoundException;
-import org.apache.cocoon.components.source.URLRewriter;
-import org.apache.cocoon.util.NetUtils;
-import org.apache.cocoon.xml.IncludeXMLConsumer;
-import org.apache.cocoon.xml.dom.DOMBuilder;
-import org.apache.excalibur.source.Source;
-import org.apache.excalibur.source.SourceException;
-import org.apache.excalibur.source.SourceNotFoundException;
-import org.apache.excalibur.source.SourceParameters;
-import org.apache.excalibur.source.SourceResolver;
-import org.apache.cocoon.core.xml.SAXParser;
-import org.apache.excalibur.xml.sax.XMLizable;
-import org.apache.excalibur.xmlizer.XMLizer;
-import org.apache.regexp.RE;
-import org.apache.regexp.RECompiler;
-import org.apache.regexp.REProgram;
-import org.apache.regexp.RESyntaxException;
-import org.w3c.dom.Document;
-import org.xml.sax.ContentHandler;
-import org.xml.sax.InputSource;
-import org.xml.sax.SAXException;
-
-/**
- * This class contains some utility methods for the source resolving.
- *
- * @version $Id$
- */
-public abstract class SourceUtil {
-
- protected static REProgram uripattern;
-
- static {
- try {
- uripattern = new RECompiler().compile("^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?$");
- } catch (RESyntaxException e) {
- // Should not happen
- throw new RuntimeException("Error parsing regular expression.", e);
- }
- }
-
- /**
- * Generates SAX events from the given source with possible URL rewriting.
- *
- * <p><b>NOTE</b>: If the implementation can produce lexical events,
- * care should be taken that <code>handler</code> can actually
- * directly implement the LexicalHandler interface!</p>
- *
- * @param source the data
- * @throws ProcessingException if no suitable converter is found
- */
- static public void toSAX(ServiceManager manager,
- Source source,
- ContentHandler handler,
- Parameters typeParameters,
- boolean filterDocumentEvent)
- throws SAXException, IOException, ProcessingException {
- // Test for url rewriting
- if (typeParameters != null
- && typeParameters.getParameter(URLRewriter.PARAMETER_MODE, null) != null) {
- handler = new URLRewriter(typeParameters, handler);
- }
-
- String mimeTypeHint = null;
- if (typeParameters != null) {
- mimeTypeHint = typeParameters.getParameter("mime-type", mimeTypeHint);
- }
- if (filterDocumentEvent) {
- IncludeXMLConsumer filter = new IncludeXMLConsumer(handler);
- toSAX(manager, source, mimeTypeHint, filter);
- } else {
- toSAX(manager, source, mimeTypeHint, handler);
- }
- }
-
- /**
- * Generates SAX events from the XMLizable and handle SAXException.
- *
- * @param source the data
- */
- public static void toSAX(XMLizable source, ContentHandler handler) throws SAXException, IOException, ProcessingException {
- try {
- source.toSAX(handler);
- } catch (SAXException e) {
- // Unwrap ProcessingException, IOException, and extreme cases of SAXExceptions.
- // Handle SourceException.
- // See also handleSAXException
- final Exception cause = e.getException();
- if (cause != null) {
- if (cause instanceof SourceException) {
- throw handle((SourceException) cause);
- }
- if (cause instanceof ProcessingException) {
- throw (ProcessingException) cause;
- }
- if (cause instanceof IOException) {
- throw (IOException) cause;
- }
- if (cause instanceof SAXException) {
- throw (SAXException) cause;
- }
- }
-
- // Throw original SAX exception
- throw e;
- }
- }
-
- /**
- * Generates SAX events from the given source.
- *
- * <p><b>NOTE</b>: If the implementation can produce lexical events,
- * care should be taken that <code>handler</code> can actually
- * directly implement the LexicalHandler interface!</p>
- *
- * @param source the data
- * @throws ProcessingException if no suitable converter is found
- */
- static public void toSAX(ServiceManager manager,
- Source source,
- ContentHandler handler)
- throws SAXException, IOException, ProcessingException {
- toSAX(manager, source, null, handler);
- }
-
- /**
- * Generates SAX events from the given source by using XMLizer.
- *
- * <p><b>NOTE</b>: If the implementation can produce lexical events,
- * care should be taken that <code>handler</code> can actually
- * directly implement the LexicalHandler interface!</p>
- *
- * @param source the data
- * @throws ProcessingException if no suitable converter is found
- */
- public static void toSAX(ServiceManager manager,
- Source source,
- String mimeTypeHint,
- ContentHandler handler)
- throws SAXException, IOException, ProcessingException {
- if (source instanceof XMLizable) {
- toSAX((XMLizable) source, handler);
- } else {
- String mimeType = source.getMimeType();
- if (null == mimeType) {
- mimeType = mimeTypeHint;
- }
-
- XMLizer xmlizer = null;
- try {
- xmlizer = (XMLizer) manager.lookup(XMLizer.ROLE);
- xmlizer.toSAX(source.getInputStream(),
- mimeType,
- source.getURI(),
- handler);
- } catch (SourceException e) {
- throw SourceUtil.handle(e);
- } catch (ServiceException e) {
- throw new ProcessingException("Exception during streaming source.", e);
- } finally {
- manager.release(xmlizer);
- }
- }
- }
-
- /**
- * Generates SAX events from the given source by using XMLizer.
- *
- * <p><b>NOTE</b>: If the implementation can produce lexical events,
- * care should be taken that <code>handler</code> can actually
- * directly implement the LexicalHandler interface!</p>
- *
- * @param source the data
- * @throws ProcessingException if no suitable converter is found
- */
- public static void toSAX(XMLizer xmlizer,
- Source source,
- String mimeTypeHint,
- ContentHandler handler)
- throws SAXException, IOException, ProcessingException {
- if (source instanceof XMLizable) {
- toSAX((XMLizable) source, handler);
- } else {
- String mimeType = source.getMimeType();
- if (null == mimeType) {
- mimeType = mimeTypeHint;
- }
- try {
- xmlizer.toSAX(source.getInputStream(),
- mimeType,
- source.getURI(),
- handler);
- } catch (SourceException e) {
- throw SourceUtil.handle(e);
- }
- }
- }
-
- /**
- * Generates character SAX events from the given source.
- *
- * @param source The data
- * @param encoding The character encoding of the data
- */
- public static void toCharacters(Source source, String encoding, ContentHandler handler) throws SAXException, IOException, ProcessingException {
- try {
- Reader r = encoding == null?
- new InputStreamReader(source.getInputStream()):
- new InputStreamReader(source.getInputStream(), encoding);
-
- int len;
- char[] chr = new char[4096];
- try {
- while ((len = r.read(chr)) > 0) {
- handler.characters(chr, 0, len);
- }
- } finally {
- r.close();
- }
- } catch (SAXException e) {
- handleSAXException(source.getURI(), e);
- }
- }
-
- /**
- * Generates SAX events from the given source by parsing it.
- *
- * <p><b>NOTE</b>: If the implementation can produce lexical events,
- * care should be taken that <code>handler</code> can actually
- * directly implement the LexicalHandler interface!</p>
- *
- * @param source the data
- * @throws ProcessingException if no suitable converter is found
- * @deprecated use {@link #parse(SAXParser, Source, ContentHandler)} instead
- */
- public static void parse(ServiceManager manager, Source source, ContentHandler handler) throws SAXException, IOException, ProcessingException {
- if (source instanceof XMLizable) {
- toSAX((XMLizable) source, handler);
- } else {
- org.apache.excalibur.xml.sax.SAXParser parser = null;
- try {
- parser = (org.apache.excalibur.xml.sax.SAXParser) manager.lookup(org.apache.excalibur.xml.sax.SAXParser.ROLE);
- parser.parse(getInputSource(source), handler);
- } catch (SourceException e) {
- throw SourceUtil.handle(e);
- } catch (ServiceException e) {
- throw new ProcessingException("Exception during parsing source.", e);
- } finally {
- manager.release(parser);
- }
- }
- }
-
- /**
- * Generates SAX events from the given source by parsing it.
- *
- * <p><b>NOTE</b>: If the implementation can produce lexical events,
- * care should be taken that <code>handler</code> can actually
- * directly implement the LexicalHandler interface!</p>
- *
- * @param source the data
- * @throws ProcessingException if error during processing source data occurs
- */
- public static void parse(SAXParser parser, Source source, ContentHandler handler) throws SAXException, IOException, ProcessingException {
- if (source instanceof XMLizable) {
- toSAX((XMLizable) source, handler);
- } else {
- try {
- parser.parse(getInputSource(source), handler);
- } catch (SourceException e) {
- throw SourceUtil.handle(e);
- }
- }
- }
-
-
- /**
- * Generates a DOM from the given source
- * @param source The data
- *
- * @return Created DOM document.
- *
- * @throws IOException If a io exception occurs.
- * @throws ProcessingException if no suitable converter is found
- * @throws SAXException If a SAX exception occurs.
- */
- public static Document toDOM(ServiceManager manager, Source source) throws SAXException, IOException, ProcessingException {
- DOMBuilder builder = new DOMBuilder();
-
- toSAX(manager, source, null, builder);
-
- Document document = builder.getDocument();
- if (document == null) {
- throw new ProcessingException("Could not build DOM for '" +
- source.getURI() + "'");
- }
-
- return document;
- }
-
- /**
- * Generates a DOM from the given source
- * @param source The data
- *
- * @return Created DOM document.
- *
- * @throws IOException If a io exception occurs.
- * @throws ProcessingException if no suitable converter is found
- * @throws SAXException If a SAX exception occurs.
- */
- public static Document toDOM(ServiceManager manager, String mimeTypeHint, Source source) throws SAXException, IOException, ProcessingException {
- DOMBuilder builder = new DOMBuilder();
-
- toSAX(manager, source, mimeTypeHint, builder);
-
- Document document = builder.getDocument();
- if (document == null) {
- throw new ProcessingException("Could not build DOM for '" +
- source.getURI() + "'");
- }
-
- return document;
- }
-
- /**
- * Make a ProcessingException from a SourceException.
- * If the exception is a SourceNotFoundException then a
- * ResourceNotFoundException is thrown.
- *
- * @param se Source exception
- * @return Created processing exception.
- */
- public static ProcessingException handle(SourceException se) {
- if (se instanceof SourceNotFoundException) {
- return new ResourceNotFoundException("Resource not found.", se);
- }
- return new ProcessingException("Exception during source resolving.",
- se);
- }
-
- /**
- * Make a ProcessingException from a SourceException.
- * If the exception is a SourceNotFoundException then a
- * ResourceNotFoundException is thrown.
- *
- * @param message Additional exception message.
- * @param se Source exception.
- * @return Created processing exception.
- */
- public static ProcessingException handle(String message, SourceException se) {
- if (se instanceof SourceNotFoundException) {
- return new ResourceNotFoundException(message, se);
- }
- return new ProcessingException(message, se);
- }
-
- /**
- * Handle SAXException catched in Generator's generate method.
- *
- * @param source Generator's source
- * @param e SAXException happened in the generator's generate method.
- */
- public static void handleSAXException(String source, SAXException e) throws ProcessingException, IOException, SAXException {
- final Exception cause = e.getException();
- if (cause != null) {
- // Unwrap ProcessingException, IOException, and extreme cases of SAXExceptions.
- // Handle SourceException.
- // See also toSax(XMLizable, ContentHandler)
- if (cause instanceof SourceException) {
- throw handle((SourceException) cause);
- }
- if (cause instanceof ProcessingException) {
- throw (ProcessingException) cause;
- }
- if (cause instanceof IOException) {
- throw (IOException) cause;
- }
- if (cause instanceof SAXException) {
- throw (SAXException) cause;
- }
- throw new ProcessingException("Could not read resource " +
- source, cause);
- }
- throw e;
- }
-
- /**
- * Get an InputSource object
- *
- * @param source Source.
- *
- * @return Input stream of the source.
- *
- * @throws IOException If a io exception occurs.
- * @throws ProcessingException If an exception occurs during
- * processing.
- */
- public static InputSource getInputSource(Source source) throws IOException, ProcessingException {
- try {
- final InputSource newObject = new InputSource(source.getInputStream());
-
- newObject.setSystemId(source.getURI());
- return newObject;
- } catch (SourceException se) {
- throw handle(se);
- }
- }
-
- /**
- * Get a <code>Source</code> object
- *
- * @param uri URI of the source.
- * @param typeParameters Type of Source query. Currently, only
- * <code>method</code> parameter (value typically <code>GET</code> or
- * <code>POST</code>) is recognized. May be <code>null</code>.
- * @param resourceParameters Parameters of the source. May be <code>null</code>
- * @param resolver Resolver for the source.
- *
- * @return The resolved source.
- *
- * @throws IOException If a io exception occurs.
- * @throws SAXException If a SAX exception occurs.
- * @throws SourceException If the source an exception throws.
- */
- public static Source getSource(String uri, Parameters typeParameters, SourceParameters resourceParameters, SourceResolver resolver) throws IOException, SAXException, SourceException {
-
- // first step: encode parameters which are already appended to the url
- int queryPos = uri.indexOf('?');
- if (queryPos != -1) {
- String queryString = uri.substring(queryPos+1);
- SourceParameters queries = new SourceParameters(queryString);
-
- if (queries.hasParameters()) {
- StringBuffer buffer = new StringBuffer(uri.substring(0, queryPos));
- char separator = '?';
-
- Iterator i = queries.getParameterNames();
- while (i.hasNext()) {
- String current = (String) i.next();
- Iterator values = queries.getParameterValues(current);
- while (values.hasNext()) {
- buffer.append(separator)
- .append(current)
- .append('=')
- .append(NetUtils.encode((String) values.next(), "utf-8"));
- separator = '&';
- }
- }
- uri = buffer.toString();
- }
- }
-
- String method = ((typeParameters!=null)
- ? typeParameters.getParameter("method", "GET")
- : "GET");
- if (method.equalsIgnoreCase("POST") &&
- (resourceParameters == null ||
- !resourceParameters.hasParameters())) {
- method = "GET";
- }
-
- if (uri.startsWith("cocoon:") && resourceParameters != null &&
- resourceParameters.hasParameters()) {
- int pos = uri.indexOf(";jsessionid=");
-
- StringBuffer buf;
- if (pos == -1) {
- buf = new StringBuffer(uri);
- } else {
- buf = new StringBuffer(uri.substring(0, pos));
- }
- buf.append(((uri.indexOf('?') == -1) ? '?' : '&'));
- buf.append(resourceParameters.getEncodedQueryString());
- uri = buf.toString();
- }
-
- Map resolverParameters = new HashMap();
- resolverParameters.put(SourceResolver.METHOD, method);
- if (typeParameters != null) {
- String encoding = typeParameters.getParameter("encoding",
- System.getProperty("file.encoding", "ISO-8859-1"));
- if (encoding != null && !"".equals(encoding)) {
- resolverParameters.put(SourceResolver.URI_ENCODING, encoding);
- }
- }
- resolverParameters.put(SourceResolver.URI_PARAMETERS,
- resourceParameters);
-
- return resolver.resolveURI(uri, null, resolverParameters);
- }
-
- /**
- * Return the scheme of a URI. Just as there are many different methods
- * of access to resources, there are a variety of schemes for identifying
- * such resources.
- * (see <a href="http://www.ietf.org/rfc/rfc2396.txt">RFC 2396</a>).
- *
- * @param uri Uniform resource identifier.
- *
- * @return Scheme of the URI.
- */
- public static String getScheme(String uri) {
- RE re = new RE(uripattern);
- if (re.match(uri)) {
- return re.getParen(2);
- } else {
- throw new IllegalArgumentException("'" + uri +
- "' is not a correct URI");
- }
- }
-
- /**
- * Return the authority of a URI. This authority is
- * typically defined by an Internet-based server or a scheme-specific
- * registry of naming authorities
- * (see <a href="http://www.ietf.org/rfc/rfc2396.txt">RFC 2396</a>).
- *
- * @param uri Uniform resource identifier.
- *
- * @return Scheme of the URI.
- */
- public static String getAuthority(String uri) {
- RE re = new RE(uripattern);
- if (re.match(uri)) {
- return re.getParen(4);
- } else {
- throw new IllegalArgumentException("'" + uri +
- "' is not a correct URI");
- }
- }
-
- /**
- * Return the path of a URI. The path contains data, specific to the
- * authority (or the scheme if there is no authority component),
- * identifying the resource within the scope of that scheme and authority
- * (see <a href="http://www.ietf.org/rfc/rfc2396.txt">RFC 2396</a>).
- *
- * @param uri Uniform resource identifier.
- *
- * @return Path of the URI.
- */
- public static String getPath(String uri) {
- RE re = new RE(uripattern);
- if (re.match(uri)) {
- return re.getParen(5);
- } else {
- throw new IllegalArgumentException("'" + uri +
- "' is not a correct URI");
- }
- }
-
- /**
- * Return the path of a URI, if the URI can't contains a authority.
- * This implementation differ to the RFC 2396.
- *
- * @param uri Uniform resource identifier.
- *
- * @return Path of the URI.
- */
- public static String getPathWithoutAuthority(String uri) {
- RE re = new RE(uripattern);
- if (re.match(uri)) {
- return re.getParen(4) + re.getParen(5);
- } else {
- throw new IllegalArgumentException("'" + uri +
- "' is not a correct URI");
- }
- }
-
- /**
- * Return the query of a URI. The query is a string of information to
- * be interpreted by the resource
- * (see <a href="http://www.ietf.org/rfc/rfc2396.txt">RFC 2396</a>).
- *
- * @param uri Uniform resource identifier.
- *
- * @return Query of the URI.
- */
- public static String getQuery(String uri) {
- RE re = new RE(uripattern);
- if (re.match(uri)) {
- return re.getParen(7);
- } else {
- throw new IllegalArgumentException("'" + uri +
- "' is not a correct URI");
- }
- }
-
- /**
- * Return the fragment of a URI. When a URI reference is used to perform
- * a retrieval action on the identified resource, the optional fragment
- * identifier, consists of additional reference information to be
- * interpreted by the user agent after the retrieval action has been
- * successfully completed
- * (see <a href="http://www.ietf.org/rfc/rfc2396.txt">RFC 2396</a>).
- *
- * @param uri Uniform resource identifier.
- *
- * @return Fragment of the URI.
- */
- public static String getFragment(String uri) {
- RE re = new RE(uripattern);
- if (re.match(uri)) {
- return re.getParen(9);
- } else {
- throw new IllegalArgumentException("'" + uri +
- "' is not a correct URI");
- }
- }
-
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.cocoon.components.source.util;
+
+import java.io.IOException;
+import java.io.InputStreamReader;
+import java.io.Reader;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.Map;
+
+import org.apache.avalon.framework.parameters.Parameters;
+import org.apache.avalon.framework.service.ServiceException;
+import org.apache.avalon.framework.service.ServiceManager;
+import org.apache.cocoon.ProcessingException;
+import org.apache.cocoon.ResourceNotFoundException;
+import org.apache.cocoon.components.source.URLRewriter;
+import org.apache.cocoon.util.NetUtils;
+import org.apache.cocoon.xml.IncludeXMLConsumer;
+import org.apache.cocoon.xml.dom.DOMBuilder;
+import org.apache.excalibur.source.Source;
+import org.apache.excalibur.source.SourceException;
+import org.apache.excalibur.source.SourceNotFoundException;
+import org.apache.excalibur.source.SourceParameters;
+import org.apache.excalibur.source.SourceResolver;
+import org.apache.cocoon.core.xml.SAXParser;
+import org.apache.excalibur.xml.sax.XMLizable;
+import org.apache.excalibur.xmlizer.XMLizer;
+import org.apache.regexp.RE;
+import org.apache.regexp.RECompiler;
+import org.apache.regexp.REProgram;
+import org.apache.regexp.RESyntaxException;
+import org.w3c.dom.Document;
+import org.xml.sax.ContentHandler;
+import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
+
+/**
+ * This class contains some utility methods for the source resolving.
+ *
+ * @version $Id$
+ */
+public abstract class SourceUtil {
+
+ protected static REProgram uripattern;
+
+ static {
+ try {
+ uripattern = new RECompiler().compile("^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?$");
+ } catch (RESyntaxException e) {
+ // Should not happen
+ throw new RuntimeException("Error parsing regular expression.", e);
+ }
+ }
+
+ /**
+ * Generates SAX events from the given source with possible URL rewriting.
+ *
+ * <p><b>NOTE</b>: If the implementation can produce lexical events,
+ * care should be taken that <code>handler</code> can actually
+ * directly implement the LexicalHandler interface!</p>
+ *
+ * @param source the data
+ * @throws ProcessingException if no suitable converter is found
+ */
+ static public void toSAX(ServiceManager manager,
+ Source source,
+ ContentHandler handler,
+ Parameters typeParameters,
+ boolean filterDocumentEvent)
+ throws SAXException, IOException, ProcessingException {
+ // Test for url rewriting
+ if (typeParameters != null
+ && typeParameters.getParameter(URLRewriter.PARAMETER_MODE, null) != null) {
+ handler = new URLRewriter(typeParameters, handler);
+ }
+
+ String mimeTypeHint = null;
+ if (typeParameters != null) {
+ mimeTypeHint = typeParameters.getParameter("mime-type", mimeTypeHint);
+ }
+ if (filterDocumentEvent) {
+ IncludeXMLConsumer filter = new IncludeXMLConsumer(handler);
+ toSAX(manager, source, mimeTypeHint, filter);
+ } else {
+ toSAX(manager, source, mimeTypeHint, handler);
+ }
+ }
+
+ /**
+ * Generates SAX events from the XMLizable and handle SAXException.
+ *
+ * @param source the data
+ */
+ public static void toSAX(XMLizable source, ContentHandler handler) throws SAXException, IOException, ProcessingException {
+ try {
+ source.toSAX(handler);
+ } catch (SAXException e) {
+ // Unwrap ProcessingException, IOException, and extreme cases of SAXExceptions.
+ // Handle SourceException.
+ // See also handleSAXException
+ final Exception cause = e.getException();
+ if (cause != null) {
+ if (cause instanceof SourceException) {
+ throw handle((SourceException) cause);
+ }
+ if (cause instanceof ProcessingException) {
+ throw (ProcessingException) cause;
+ }
+ if (cause instanceof IOException) {
+ throw (IOException) cause;
+ }
+ if (cause instanceof SAXException) {
+ throw (SAXException) cause;
+ }
+ }
+
+ // Throw original SAX exception
+ throw e;
+ }
+ }
+
+ /**
+ * Generates SAX events from the given source.
+ *
+ * <p><b>NOTE</b>: If the implementation can produce lexical events,
+ * care should be taken that <code>handler</code> can actually
+ * directly implement the LexicalHandler interface!</p>
+ *
+ * @param source the data
+ * @throws ProcessingException if no suitable converter is found
+ */
+ static public void toSAX(ServiceManager manager,
+ Source source,
+ ContentHandler handler)
+ throws SAXException, IOException, ProcessingException {
+ toSAX(manager, source, null, handler);
+ }
+
+ /**
+ * Generates SAX events from the given source by using XMLizer.
+ *
+ * <p><b>NOTE</b>: If the implementation can produce lexical events,
+ * care should be taken that <code>handler</code> can actually
+ * directly implement the LexicalHandler interface!</p>
+ *
+ * @param source the data
+ * @throws ProcessingException if no suitable converter is found
+ */
+ public static void toSAX(ServiceManager manager,
+ Source source,
+ String mimeTypeHint,
+ ContentHandler handler)
+ throws SAXException, IOException, ProcessingException {
+ if (source instanceof XMLizable) {
+ toSAX((XMLizable) source, handler);
+ } else {
+ String mimeType = source.getMimeType();
+ if (null == mimeType) {
+ mimeType = mimeTypeHint;
+ }
+
+ XMLizer xmlizer = null;
+ try {
+ xmlizer = (XMLizer) manager.lookup(XMLizer.ROLE);
+ xmlizer.toSAX(source.getInputStream(),
+ mimeType,
+ source.getURI(),
+ handler);
+ } catch (SourceException e) {
+ throw SourceUtil.handle(e);
+ } catch (ServiceException e) {
+ throw new ProcessingException("Exception during streaming source.", e);
+ } finally {
+ manager.release(xmlizer);
+ }
+ }
+ }
+
+ /**
+ * Generates SAX events from the given source by using XMLizer.
+ *
+ * <p><b>NOTE</b>: If the implementation can produce lexical events,
+ * care should be taken that <code>handler</code> can actually
+ * directly implement the LexicalHandler interface!</p>
+ *
+ * @param source the data
+ * @throws ProcessingException if no suitable converter is found
+ */
+ public static void toSAX(XMLizer xmlizer,
+ Source source,
+ String mimeTypeHint,
+ ContentHandler handler)
+ throws SAXException, IOException, ProcessingException {
+ if (source instanceof XMLizable) {
+ toSAX((XMLizable) source, handler);
+ } else {
+ String mimeType = source.getMimeType();
+ if (null == mimeType) {
+ mimeType = mimeTypeHint;
+ }
+ try {
+ xmlizer.toSAX(source.getInputStream(),
+ mimeType,
+ source.getURI(),
+ handler);
+ } catch (SourceException e) {
+ throw SourceUtil.handle(e);
+ }
+ }
+ }
+
+ /**
+ * Generates character SAX events from the given source.
+ *
+ * @param source The data
+ * @param encoding The character encoding of the data
+ */
+ public static void toCharacters(Source source, String encoding, ContentHandler handler) throws SAXException, IOException, ProcessingException {
+ try {
+ Reader r = encoding == null?
+ new InputStreamReader(source.getInputStream()):
+ new InputStreamReader(source.getInputStream(), encoding);
+
+ int len;
+ char[] chr = new char[4096];
+ try {
+ while ((len = r.read(chr)) > 0) {
+ handler.characters(chr, 0, len);
+ }
+ } finally {
+ r.close();
+ }
+ } catch (SAXException e) {
+ handleSAXException(source.getURI(), e);
+ }
+ }
+
+ /**
+ * Generates SAX events from the given source by parsing it.
+ *
+ * <p><b>NOTE</b>: If the implementation can produce lexical events,
+ * care should be taken that <code>handler</code> can actually
+ * directly implement the LexicalHandler interface!</p>
+ *
+ * @param source the data
+ * @throws ProcessingException if no suitable converter is found
+ * @deprecated use {@link #parse(SAXParser, Source, ContentHandler)} instead
+ */
+ public static void parse(ServiceManager manager, Source source, ContentHandler handler) throws SAXException, IOException, ProcessingException {
+ if (source instanceof XMLizable) {
+ toSAX((XMLizable) source, handler);
+ } else {
+ org.apache.excalibur.xml.sax.SAXParser parser = null;
+ try {
+ parser = (org.apache.excalibur.xml.sax.SAXParser) manager.lookup(org.apache.excalibur.xml.sax.SAXParser.ROLE);
+ parser.parse(getInputSource(source), handler);
+ } catch (SourceException e) {
+ throw SourceUtil.handle(e);
+ } catch (ServiceException e) {
+ throw new ProcessingException("Exception during parsing source.", e);
+ } finally {
+ manager.release(parser);
+ }
+ }
+ }
+
+ /**
+ * Generates SAX events from the given source by parsing it.
+ *
+ * <p><b>NOTE</b>: If the implementation can produce lexical events,
+ * care should be taken that <code>handler</code> can actually
+ * directly implement the LexicalHandler interface!</p>
+ *
+ * @param source the data
+ * @throws ProcessingException if error during processing source data occurs
+ */
+ public static void parse(SAXParser parser, Source source, ContentHandler handler) throws SAXException, IOException, ProcessingException {
+ if (source instanceof XMLizable) {
+ toSAX((XMLizable) source, handler);
+ } else {
+ try {
+ parser.parse(getInputSource(source), handler);
+ } catch (SourceException e) {
+ throw SourceUtil.handle(e);
+ }
+ }
+ }
+
+
+ /**
+ * Generates a DOM from the given source
+ * @param source The data
+ *
+ * @return Created DOM document.
+ *
+ * @throws IOException If a io exception occurs.
+ * @throws ProcessingException if no suitable converter is found
+ * @throws SAXException If a SAX exception occurs.
+ */
+ public static Document toDOM(ServiceManager manager, Source source) throws SAXException, IOException, ProcessingException {
+ DOMBuilder builder = new DOMBuilder();
+
+ toSAX(manager, source, null, builder);
+
+ Document document = builder.getDocument();
+ if (document == null) {
+ throw new ProcessingException("Could not build DOM for '" +
+ source.getURI() + "'");
+ }
+
+ return document;
+ }
+
+ /**
+ * Generates a DOM from the given source
+ * @param source The data
+ *
+ * @return Created DOM document.
+ *
+ * @throws IOException If a io exception occurs.
+ * @throws ProcessingException if no suitable converter is found
+ * @throws SAXException If a SAX exception occurs.
+ */
+ public static Document toDOM(ServiceManager manager, String mimeTypeHint, Source source) throws SAXException, IOException, ProcessingException {
+ DOMBuilder builder = new DOMBuilder();
+
+ toSAX(manager, source, mimeTypeHint, builder);
+
+ Document document = builder.getDocument();
+ if (document == null) {
+ throw new ProcessingException("Could not build DOM for '" +
+ source.getURI() + "'");
+ }
+
+ return document;
+ }
+
+ /**
+ * Make a ProcessingException from a SourceException.
+ * If the exception is a SourceNotFoundException then a
+ * ResourceNotFoundException is thrown.
+ *
+ * @param se Source exception
+ * @return Created processing exception.
+ */
+ public static ProcessingException handle(SourceException se) {
+ if (se instanceof SourceNotFoundException) {
+ return new ResourceNotFoundException("Resource not found.", se);
+ }
+ return new ProcessingException("Exception during source resolving.",
+ se);
+ }
+
+ /**
+ * Make a ProcessingException from a SourceException.
+ * If the exception is a SourceNotFoundException then a
+ * ResourceNotFoundException is thrown.
+ *
+ * @param message Additional exception message.
+ * @param se Source exception.
+ * @return Created processing exception.
+ */
+ public static ProcessingException handle(String message, SourceException se) {
+ if (se instanceof SourceNotFoundException) {
+ return new ResourceNotFoundException(message, se);
+ }
+ return new ProcessingException(message, se);
+ }
+
+ /**
+ * Handle SAXException catched in Generator's generate method.
+ *
+ * @param source Generator's source
+ * @param e SAXException happened in the generator's generate method.
+ */
+ public static void handleSAXException(String source, SAXException e) throws ProcessingException, IOException, SAXException {
+ final Exception cause = e.getException();
+ if (cause != null) {
+ // Unwrap ProcessingException, IOException, and extreme cases of SAXExceptions.
+ // Handle SourceException.
+ // See also toSax(XMLizable, ContentHandler)
+ if (cause instanceof SourceException) {
+ throw handle((SourceException) cause);
+ }
+ if (cause instanceof ProcessingException) {
+ throw (ProcessingException) cause;
+ }
+ if (cause instanceof IOException) {
+ throw (IOException) cause;
+ }
+ if (cause instanceof SAXException) {
+ throw (SAXException) cause;
+ }
+ throw new ProcessingException("Could not read resource " +
+ source, cause);
+ }
+ throw e;
+ }
+
+ /**
+ * Get an InputSource object
+ *
+ * @param source Source.
+ *
+ * @return Input stream of the source.
+ *
+ * @throws IOException If a io exception occurs.
+ * @throws ProcessingException If an exception occurs during
+ * processing.
+ */
+ public static InputSource getInputSource(Source source) throws IOException, ProcessingException {
+ try {
+ final InputSource newObject = new InputSource(source.getInputStream());
+
+ newObject.setSystemId(source.getURI());
+ return newObject;
+ } catch (SourceException se) {
+ throw handle(se);
+ }
+ }
+
+ /**
+ * Get a <code>Source</code> object
+ *
+ * @param uri URI of the source.
+ * @param typeParameters Type of Source query. Currently, only
+ * <code>method</code> parameter (value typically <code>GET</code> or
+ * <code>POST</code>) is recognized. May be <code>null</code>.
+ * @param resourceParameters Parameters of the source. May be <code>null</code>
+ * @param resolver Resolver for the source.
+ *
+ * @return The resolved source.
+ *
+ * @throws IOException If a io exception occurs.
+ * @throws SAXException If a SAX exception occurs.
+ * @throws SourceException If the source an exception throws.
+ */
+ public static Source getSource(String uri, Parameters typeParameters, SourceParameters resourceParameters, SourceResolver resolver) throws IOException, SAXException, SourceException {
+
+ // first step: encode parameters which are already appended to the url
+ int queryPos = uri.indexOf('?');
+ if (queryPos != -1) {
+ String queryString = uri.substring(queryPos+1);
+ SourceParameters queries = new SourceParameters(queryString);
+
+ if (queries.hasParameters()) {
+ StringBuffer buffer = new StringBuffer(uri.substring(0, queryPos));
+ char separator = '?';
+
+ Iterator i = queries.getParameterNames();
+ while (i.hasNext()) {
+ String current = (String) i.next();
+ Iterator values = queries.getParameterValues(current);
+ while (values.hasNext()) {
+ buffer.append(separator)
+ .append(current)
+ .append('=')
+ .append(NetUtils.encode((String) values.next(), "utf-8"));
+ separator = '&';
+ }
+ }
+ uri = buffer.toString();
+ }
+ }
+
+ String method = ((typeParameters!=null)
+ ? typeParameters.getParameter("method", "GET")
+ : "GET");
+ if (method.equalsIgnoreCase("POST") &&
+ (resourceParameters == null ||
+ !resourceParameters.hasParameters())) {
+ method = "GET";
+ }
+
+ if (uri.startsWith("cocoon:") && resourceParameters != null &&
+ resourceParameters.hasParameters()) {
+ int pos = uri.indexOf(";jsessionid=");
+
+ StringBuffer buf;
+ if (pos == -1) {
+ buf = new StringBuffer(uri);
+ } else {
+ buf = new StringBuffer(uri.substring(0, pos));
+ }
+ buf.append(((uri.indexOf('?') == -1) ? '?' : '&'));
+ buf.append(resourceParameters.getEncodedQueryString());
+ uri = buf.toString();
+ }
+
+ Map resolverParameters = new HashMap();
+ resolverParameters.put(SourceResolver.METHOD, method);
+ if (typeParameters != null) {
+ String encoding = typeParameters.getParameter("encoding",
+ System.getProperty("file.encoding", "ISO-8859-1"));
+ if (encoding != null && !"".equals(encoding)) {
+ resolverParameters.put(SourceResolver.URI_ENCODING, encoding);
+ }
+ }
+ resolverParameters.put(SourceResolver.URI_PARAMETERS,
+ resourceParameters);
+
+ return resolver.resolveURI(uri, null, resolverParameters);
+ }
+
+ /**
+ * Return the scheme of a URI. Just as there are many different methods
+ * of access to resources, there are a variety of schemes for identifying
+ * such resources.
+ * (see <a href="http://www.ietf.org/rfc/rfc2396.txt">RFC 2396</a>).
+ *
+ * @param uri Uniform resource identifier.
+ *
+ * @return Scheme of the URI.
+ */
+ public static String getScheme(String uri) {
+ RE re = new RE(uripattern);
+ if (re.match(uri)) {
+ return re.getParen(2);
+ } else {
+ throw new IllegalArgumentException("'" + uri +
+ "' is not a correct URI");
+ }
+ }
+
+ /**
+ * Return the authority of a URI. This authority is
+ * typically defined by an Internet-based server or a scheme-specific
+ * registry of naming authorities
+ * (see <a href="http://www.ietf.org/rfc/rfc2396.txt">RFC 2396</a>).
+ *
+ * @param uri Uniform resource identifier.
+ *
+ * @return Scheme of the URI.
+ */
+ public static String getAuthority(String uri) {
+ RE re = new RE(uripattern);
+ if (re.match(uri)) {
+ return re.getParen(4);
+ } else {
+ throw new IllegalArgumentException("'" + uri +
+ "' is not a correct URI");
+ }
+ }
+
+ /**
+ * Return the path of a URI. The path contains data, specific to the
+ * authority (or the scheme if there is no authority component),
+ * identifying the resource within the scope of that scheme and authority
+ * (see <a href="http://www.ietf.org/rfc/rfc2396.txt">RFC 2396</a>).
+ *
+ * @param uri Uniform resource identifier.
+ *
+ * @return Path of the URI.
+ */
+ public static String getPath(String uri) {
+ RE re = new RE(uripattern);
+ if (re.match(uri)) {
+ return re.getParen(5);
+ } else {
+ throw new IllegalArgumentException("'" + uri +
+ "' is not a correct URI");
+ }
+ }
+
+ /**
+ * Return the path of a URI, if the URI can't contains a authority.
+ * This implementation differ to the RFC 2396.
+ *
+ * @param uri Uniform resource identifier.
+ *
+ * @return Path of the URI.
+ */
+ public static String getPathWithoutAuthority(String uri) {
+ RE re = new RE(uripattern);
+ if (re.match(uri)) {
+ return re.getParen(4) + re.getParen(5);
+ } else {
+ throw new IllegalArgumentException("'" + uri +
+ "' is not a correct URI");
+ }
+ }
+
+ /**
+ * Return the query of a URI. The query is a string of information to
+ * be interpreted by the resource
+ * (see <a href="http://www.ietf.org/rfc/rfc2396.txt">RFC 2396</a>).
+ *
+ * @param uri Uniform resource identifier.
+ *
+ * @return Query of the URI.
+ */
+ public static String getQuery(String uri) {
+ RE re = new RE(uripattern);
+ if (re.match(uri)) {
+ return re.getParen(7);
+ } else {
+ throw new IllegalArgumentException("'" + uri +
+ "' is not a correct URI");
+ }
+ }
+
+ /**
+ * Return the fragment of a URI. When a URI reference is used to perform
+ * a retrieval action on the identified resource, the optional fragment
+ * identifier, consists of additional reference information to be
+ * interpreted by the user agent after the retrieval action has been
+ * successfully completed
+ * (see <a href="http://www.ietf.org/rfc/rfc2396.txt">RFC 2396</a>).
+ *
+ * @param uri Uniform resource identifier.
+ *
+ * @return Fragment of the URI.
+ */
+ public static String getFragment(String uri) {
+ RE re = new RE(uripattern);
+ if (re.match(uri)) {
+ return re.getParen(9);
+ } else {
+ throw new IllegalArgumentException("'" + uri +
+ "' is not a correct URI");
+ }
+ }
+
+}
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/components/source/util/SourceUtil.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/components/source/util/SourceUtil.java
------------------------------------------------------------------------------
svn:keywords = Id Revision Author Date
Modified: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoFactoryBean.java
URL: http://svn.apache.org/viewvc/cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoFactoryBean.java?rev=587751&r1=587750&r2=587751&view=diff
==============================================================================
--- cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoFactoryBean.java (original)
+++ cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoFactoryBean.java Tue Oct 23 19:41:36 2007
@@ -1,94 +1,94 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.cocoon.core.container.spring.pipeline;
-
-import java.util.Map;
-
-import org.apache.cocoon.components.pipeline.impl.PipelineComponentInfo;
-import org.springframework.beans.BeansException;
-import org.springframework.beans.factory.BeanFactory;
-import org.springframework.beans.factory.BeanFactoryAware;
-import org.springframework.beans.factory.FactoryBean;
-import org.springframework.beans.factory.HierarchicalBeanFactory;
-
-/**
- * This spring factory bean adds the processor component info to the bean factory.
- *
- * @since 2.2
- * @version $Id: ProcessorComponentInfoFactoryBean.java 448473 2006-09-21 06:22:51Z crossley $
- */
-public class PipelineComponentInfoFactoryBean
- implements FactoryBean, BeanFactoryAware {
-
- /** The bean factory. */
- protected BeanFactory beanFactory;
-
- protected Map data;
-
- protected PipelineComponentInfo info;
-
- /**
- * @see org.springframework.beans.factory.BeanFactoryAware#setBeanFactory(org.springframework.beans.factory.BeanFactory)
- */
- public void setBeanFactory(BeanFactory factory) throws BeansException {
- this.beanFactory = factory;
- }
-
- protected void init()
- throws Exception {
- PipelineComponentInfo parent = null;
- if ( this.beanFactory instanceof HierarchicalBeanFactory ) {
- BeanFactory parentFactory = ((HierarchicalBeanFactory)this.beanFactory).getParentBeanFactory();
- if ( parentFactory != null && parentFactory.containsBean(PipelineComponentInfo.ROLE) ) {
- parent = (PipelineComponentInfo)parentFactory.getBean(PipelineComponentInfo.ROLE);
- }
- }
- this.info = new PipelineComponentInfo(parent);
- if ( this.data != null ) {
- info.setData(data);
- }
- }
-
- /**
- * @see org.springframework.beans.factory.FactoryBean#getObject()
- */
- public Object getObject() throws Exception {
- return this.info;
- }
-
- /**
- * @see org.springframework.beans.factory.FactoryBean#getObjectType()
- */
- public Class getObjectType() {
- return PipelineComponentInfo.class;
- }
-
- /**
- * @see org.springframework.beans.factory.FactoryBean#isSingleton()
- */
- public boolean isSingleton() {
- return true;
- }
-
- public Map getData() {
- return data;
- }
-
- public void setData(Map data) {
- this.data = data;
- }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.cocoon.core.container.spring.pipeline;
+
+import java.util.Map;
+
+import org.apache.cocoon.components.pipeline.impl.PipelineComponentInfo;
+import org.springframework.beans.BeansException;
+import org.springframework.beans.factory.BeanFactory;
+import org.springframework.beans.factory.BeanFactoryAware;
+import org.springframework.beans.factory.FactoryBean;
+import org.springframework.beans.factory.HierarchicalBeanFactory;
+
+/**
+ * This spring factory bean adds the processor component info to the bean factory.
+ *
+ * @since 2.2
+ * @version $Id$
+ */
+public class PipelineComponentInfoFactoryBean
+ implements FactoryBean, BeanFactoryAware {
+
+ /** The bean factory. */
+ protected BeanFactory beanFactory;
+
+ protected Map data;
+
+ protected PipelineComponentInfo info;
+
+ /**
+ * @see org.springframework.beans.factory.BeanFactoryAware#setBeanFactory(org.springframework.beans.factory.BeanFactory)
+ */
+ public void setBeanFactory(BeanFactory factory) throws BeansException {
+ this.beanFactory = factory;
+ }
+
+ protected void init()
+ throws Exception {
+ PipelineComponentInfo parent = null;
+ if ( this.beanFactory instanceof HierarchicalBeanFactory ) {
+ BeanFactory parentFactory = ((HierarchicalBeanFactory)this.beanFactory).getParentBeanFactory();
+ if ( parentFactory != null && parentFactory.containsBean(PipelineComponentInfo.ROLE) ) {
+ parent = (PipelineComponentInfo)parentFactory.getBean(PipelineComponentInfo.ROLE);
+ }
+ }
+ this.info = new PipelineComponentInfo(parent);
+ if ( this.data != null ) {
+ info.setData(data);
+ }
+ }
+
+ /**
+ * @see org.springframework.beans.factory.FactoryBean#getObject()
+ */
+ public Object getObject() throws Exception {
+ return this.info;
+ }
+
+ /**
+ * @see org.springframework.beans.factory.FactoryBean#getObjectType()
+ */
+ public Class getObjectType() {
+ return PipelineComponentInfo.class;
+ }
+
+ /**
+ * @see org.springframework.beans.factory.FactoryBean#isSingleton()
+ */
+ public boolean isSingleton() {
+ return true;
+ }
+
+ public Map getData() {
+ return data;
+ }
+
+ public void setData(Map data) {
+ this.data = data;
+ }
+}
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoFactoryBean.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoFactoryBean.java
------------------------------------------------------------------------------
svn:keywords = Id Revision Author Date
Modified: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoInitializer.java
URL: http://svn.apache.org/viewvc/cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoInitializer.java?rev=587751&r1=587750&r2=587751&view=diff
==============================================================================
--- cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoInitializer.java (original)
+++ cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoInitializer.java Tue Oct 23 19:41:36 2007
@@ -1,95 +1,95 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- * implied.
- *
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.cocoon.core.container.spring.pipeline;
-
-import java.util.Map;
-import java.util.StringTokenizer;
-
-import org.apache.cocoon.components.pipeline.impl.PipelineComponentInfo;
-
-
-/**
- * @version $Id$
- * @since 2.2
- */
-public class PipelineComponentInfoInitializer {
- private PipelineComponentInfo info;
- private String componentName;
- private String mimeType;
- private String label;
- private String hint;
- private Map data;
-
- public void init() {
- if (this.mimeType != null)
- this.info.setMimeType(this.componentName, this.mimeType);
- if (this.label != null) {
- StringTokenizer st = new StringTokenizer(this.label, " ,", false);
- String[] labels = new String[st.countTokens()];
- for (int tokenIdx = 0; tokenIdx < labels.length; tokenIdx++) {
- labels[tokenIdx] = st.nextToken();
- }
- this.info.setLabels(this.componentName, labels);
- }
- if (this.hint != null)
- this.info.setPipelineHint(this.componentName, this.hint);
- if (this.data != null)
- this.info.addData(data);
- }
-
- /**
- * @param info
- */
- public void setInfo(PipelineComponentInfo info) {
- this.info = info;
- }
-
- /**
- * @param componentName
- */
- public void setComponentName(String componentName) {
- this.componentName = componentName;
- }
- /**
- * @param hint
- */
- public void setHint(String hint) {
- this.hint = hint;
- }
- /**
- * @param label
- */
- public void setLabel(String label) {
- this.label = label;
- }
- /**
- * @param mimeType
- */
- public void setMimeType(String mimeType) {
- this.mimeType = mimeType;
- }
-
- /**
- * @param data the data to set
- */
- public void setData(Map data) {
- this.data = data;
- }
-
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ * implied.
+ *
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.cocoon.core.container.spring.pipeline;
+
+import java.util.Map;
+import java.util.StringTokenizer;
+
+import org.apache.cocoon.components.pipeline.impl.PipelineComponentInfo;
+
+
+/**
+ * @version $Id$
+ * @since 2.2
+ */
+public class PipelineComponentInfoInitializer {
+ private PipelineComponentInfo info;
+ private String componentName;
+ private String mimeType;
+ private String label;
+ private String hint;
+ private Map data;
+
+ public void init() {
+ if (this.mimeType != null)
+ this.info.setMimeType(this.componentName, this.mimeType);
+ if (this.label != null) {
+ StringTokenizer st = new StringTokenizer(this.label, " ,", false);
+ String[] labels = new String[st.countTokens()];
+ for (int tokenIdx = 0; tokenIdx < labels.length; tokenIdx++) {
+ labels[tokenIdx] = st.nextToken();
+ }
+ this.info.setLabels(this.componentName, labels);
+ }
+ if (this.hint != null)
+ this.info.setPipelineHint(this.componentName, this.hint);
+ if (this.data != null)
+ this.info.addData(data);
+ }
+
+ /**
+ * @param info
+ */
+ public void setInfo(PipelineComponentInfo info) {
+ this.info = info;
+ }
+
+ /**
+ * @param componentName
+ */
+ public void setComponentName(String componentName) {
+ this.componentName = componentName;
+ }
+ /**
+ * @param hint
+ */
+ public void setHint(String hint) {
+ this.hint = hint;
+ }
+ /**
+ * @param label
+ */
+ public void setLabel(String label) {
+ this.label = label;
+ }
+ /**
+ * @param mimeType
+ */
+ public void setMimeType(String mimeType) {
+ this.mimeType = mimeType;
+ }
+
+ /**
+ * @param data the data to set
+ */
+ public void setData(Map data) {
+ this.data = data;
+ }
+
+}
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoInitializer.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoInitializer.java
------------------------------------------------------------------------------
svn:keywords = Id Revision Author Date
Modified: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoInitializerDecorator.java
URL: http://svn.apache.org/viewvc/cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoInitializerDecorator.java?rev=587751&r1=587750&r2=587751&view=diff
==============================================================================
--- cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoInitializerDecorator.java (original)
+++ cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoInitializerDecorator.java Tue Oct 23 19:41:36 2007
@@ -1,98 +1,98 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- * implied.
- *
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.cocoon.core.container.spring.pipeline;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-import org.apache.cocoon.components.pipeline.impl.PipelineComponentInfo;
-import org.springframework.beans.factory.config.BeanDefinitionHolder;
-import org.springframework.beans.factory.support.AbstractBeanDefinition;
-import org.springframework.beans.factory.support.BeanDefinitionBuilder;
-import org.springframework.beans.factory.xml.BeanDefinitionDecorator;
-import org.springframework.beans.factory.xml.ParserContext;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-
-/**
- * @version $Id$
- * @since 2.2
- */
-public class PipelineComponentInfoInitializerDecorator implements
- BeanDefinitionDecorator {
-
- private static final String[] EMPTY_STRING_ARRAY = new String[0];
-
- /* (non-Javadoc)
- * @see org.springframework.beans.factory.xml.BeanDefinitionDecorator#decorate(org.w3c.dom.Node, org.springframework.beans.factory.config.BeanDefinitionHolder, org.springframework.beans.factory.xml.ParserContext)
- */
- public BeanDefinitionHolder decorate(Node source, BeanDefinitionHolder holder, ParserContext ctx) {
- registerPipelineComponentInfo(ctx);
- String initializerBeanName = registerPipelineComponentInfoInitializer(source, holder, ctx);
- createDependencyOnPipelineComponentInfoInitializer(holder, initializerBeanName);
- return holder;
- }
-
- private void registerPipelineComponentInfo(ParserContext ctx) {
- if (!ctx.getRegistry().containsBeanDefinition(PipelineComponentInfo.ROLE)) {
- BeanDefinitionBuilder defBuilder = BeanDefinitionBuilder.rootBeanDefinition(PipelineComponentInfoFactoryBean.class);
- defBuilder.setSingleton(true);
- defBuilder.setLazyInit(false);
- defBuilder.setInitMethodName("init");
- ctx.getRegistry().registerBeanDefinition(PipelineComponentInfo.ROLE, defBuilder.getBeanDefinition());
- }
- }
-
- private String registerPipelineComponentInfoInitializer(Node source, BeanDefinitionHolder holder, ParserContext ctx) {
- String componentName = holder.getBeanName();
- String mimeType = ((Element)source).hasAttribute("mime-type") ? ((Element)source).getAttribute("mime-type") : null;
- String label = ((Element)source).hasAttribute("label") ? ((Element)source).getAttribute("label") : null;
- String hint = ((Element)source).hasAttribute("hint") ? ((Element)source).getAttribute("hint") : null;
-
- BeanDefinitionBuilder initializer = BeanDefinitionBuilder.rootBeanDefinition(PipelineComponentInfoInitializer.class);
- initializer.addPropertyReference("info", PipelineComponentInfo.ROLE);
- initializer.addPropertyValue("componentName", componentName);
- if (mimeType != null)
- initializer.addPropertyValue("mimeType", mimeType);
- if (label != null)
- initializer.addPropertyValue("label", label);
- if (hint != null)
- initializer.addPropertyValue("hint", hint);
- initializer.setInitMethodName("init");
-
- String beanName = componentName + "/info";
- ctx.getRegistry().registerBeanDefinition(beanName, initializer.getBeanDefinition());
-
- return beanName;
- }
-
- private void createDependencyOnPipelineComponentInfoInitializer(BeanDefinitionHolder holder, String initializerBeanName) {
- AbstractBeanDefinition definition = ((AbstractBeanDefinition) holder.getBeanDefinition());
- String[] dependsOn = definition.getDependsOn();
- if (dependsOn == null) {
- dependsOn = new String[]{initializerBeanName};
- } else {
- List dependencies = new ArrayList(Arrays.asList(dependsOn));
- dependencies.add(initializerBeanName);
- dependsOn = (String[]) dependencies.toArray(EMPTY_STRING_ARRAY);
- }
- definition.setDependsOn(dependsOn);
- }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ * implied.
+ *
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.cocoon.core.container.spring.pipeline;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
+import org.apache.cocoon.components.pipeline.impl.PipelineComponentInfo;
+import org.springframework.beans.factory.config.BeanDefinitionHolder;
+import org.springframework.beans.factory.support.AbstractBeanDefinition;
+import org.springframework.beans.factory.support.BeanDefinitionBuilder;
+import org.springframework.beans.factory.xml.BeanDefinitionDecorator;
+import org.springframework.beans.factory.xml.ParserContext;
+import org.w3c.dom.Element;
+import org.w3c.dom.Node;
+
+/**
+ * @version $Id$
+ * @since 2.2
+ */
+public class PipelineComponentInfoInitializerDecorator implements
+ BeanDefinitionDecorator {
+
+ private static final String[] EMPTY_STRING_ARRAY = new String[0];
+
+ /* (non-Javadoc)
+ * @see org.springframework.beans.factory.xml.BeanDefinitionDecorator#decorate(org.w3c.dom.Node, org.springframework.beans.factory.config.BeanDefinitionHolder, org.springframework.beans.factory.xml.ParserContext)
+ */
+ public BeanDefinitionHolder decorate(Node source, BeanDefinitionHolder holder, ParserContext ctx) {
+ registerPipelineComponentInfo(ctx);
+ String initializerBeanName = registerPipelineComponentInfoInitializer(source, holder, ctx);
+ createDependencyOnPipelineComponentInfoInitializer(holder, initializerBeanName);
+ return holder;
+ }
+
+ private void registerPipelineComponentInfo(ParserContext ctx) {
+ if (!ctx.getRegistry().containsBeanDefinition(PipelineComponentInfo.ROLE)) {
+ BeanDefinitionBuilder defBuilder = BeanDefinitionBuilder.rootBeanDefinition(PipelineComponentInfoFactoryBean.class);
+ defBuilder.setSingleton(true);
+ defBuilder.setLazyInit(false);
+ defBuilder.setInitMethodName("init");
+ ctx.getRegistry().registerBeanDefinition(PipelineComponentInfo.ROLE, defBuilder.getBeanDefinition());
+ }
+ }
+
+ private String registerPipelineComponentInfoInitializer(Node source, BeanDefinitionHolder holder, ParserContext ctx) {
+ String componentName = holder.getBeanName();
+ String mimeType = ((Element)source).hasAttribute("mime-type") ? ((Element)source).getAttribute("mime-type") : null;
+ String label = ((Element)source).hasAttribute("label") ? ((Element)source).getAttribute("label") : null;
+ String hint = ((Element)source).hasAttribute("hint") ? ((Element)source).getAttribute("hint") : null;
+
+ BeanDefinitionBuilder initializer = BeanDefinitionBuilder.rootBeanDefinition(PipelineComponentInfoInitializer.class);
+ initializer.addPropertyReference("info", PipelineComponentInfo.ROLE);
+ initializer.addPropertyValue("componentName", componentName);
+ if (mimeType != null)
+ initializer.addPropertyValue("mimeType", mimeType);
+ if (label != null)
+ initializer.addPropertyValue("label", label);
+ if (hint != null)
+ initializer.addPropertyValue("hint", hint);
+ initializer.setInitMethodName("init");
+
+ String beanName = componentName + "/info";
+ ctx.getRegistry().registerBeanDefinition(beanName, initializer.getBeanDefinition());
+
+ return beanName;
+ }
+
+ private void createDependencyOnPipelineComponentInfoInitializer(BeanDefinitionHolder holder, String initializerBeanName) {
+ AbstractBeanDefinition definition = ((AbstractBeanDefinition) holder.getBeanDefinition());
+ String[] dependsOn = definition.getDependsOn();
+ if (dependsOn == null) {
+ dependsOn = new String[]{initializerBeanName};
+ } else {
+ List dependencies = new ArrayList(Arrays.asList(dependsOn));
+ dependencies.add(initializerBeanName);
+ dependsOn = (String[]) dependencies.toArray(EMPTY_STRING_ARRAY);
+ }
+ definition.setDependsOn(dependsOn);
+ }
+}
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoInitializerDecorator.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineComponentInfoInitializerDecorator.java
------------------------------------------------------------------------------
svn:keywords = Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/core/container/spring/pipeline/PipelineNamespaceHandler.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/AbstractEnvironment.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/ForwardRedirector.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/http/ContextURLException.java
------------------------------------------------------------------------------
svn:keywords = Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/http/HttpContext.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/http/HttpCookie.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/http/HttpEnvironment.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/http/HttpRequest.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/http/HttpResponse.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/http/HttpSession.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/http/RequestEncodingException.java
------------------------------------------------------------------------------
svn:keywords = Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/impl/AbstractContext.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/impl/AbstractRequest.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/impl/AbstractResponse.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/impl/AbstractSession.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/impl/BaseMap.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/impl/ContextMap.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/impl/RequestHeaderMap.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/impl/RequestMap.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/impl/RequestParameterMap.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/environment/impl/SessionMap.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/generation/AbstractGenerator.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/generation/ServiceableGenerator.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/generation/ServletGenerator.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/reading/AbstractReader.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/reading/ServiceableReader.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/serialization/AbstractSerializer.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/serialization/AbstractTextSerializer.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/transformation/AbstractDOMTransformer.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/transformation/AbstractExtractionTransformer.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/transformation/AbstractSAXTransformer.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/transformation/AbstractTransformer.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/transformation/ServiceableTransformer.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/transformation/helpers/NOPRecorder.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/transformation/helpers/ParametersRecorder.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/transformation/helpers/TextRecorder.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/xml/AbstractSAXFragment.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/xml/AbstractXMLConsumer.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/xml/AbstractXMLPipe.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/xml/AbstractXMLProducer.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/xml/AttributesImpl.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/xml/ContentHandlerWrapper.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/xml/DefaultLexicalHandler.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/xml/EmbeddedXMLPipe.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date
Propchange: cocoon/trunk/core/cocoon-pipeline/cocoon-pipeline-impl/src/main/java/org/apache/cocoon/xml/ImmutableAttributesImpl.java
------------------------------------------------------------------------------
--- svn:keywords (original)
+++ svn:keywords Tue Oct 23 19:41:36 2007
@@ -1 +1 @@
-Id
+Id Revision Author Date