cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From upayav...@apache.org
Subject cvs commit: cocoon-2.1/src/java/org/apache/cocoon/bean CocoonBean.java
Date Wed, 04 Jun 2003 13:48:51 GMT
upayavira    2003/06/04 06:48:50

  Modified:    src/java/org/apache/cocoon Constants.java
               src/java/org/apache/cocoon/bean CocoonBean.java
  Log:
  Returning INDEX_URI to Constants.java (from CocoonBean.java)
  
  Revision  Changes    Path
  1.6       +11 -5     cocoon-2.1/src/java/org/apache/cocoon/Constants.java
  
  Index: Constants.java
  ===================================================================
  RCS file: /home/cvs/cocoon-2.1/src/java/org/apache/cocoon/Constants.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- Constants.java	4 Jun 2003 09:25:53 -0000	1.5
  +++ Constants.java	4 Jun 2003 13:48:50 -0000	1.6
  @@ -65,9 +65,9 @@
   
       /** Our properties are now here: */
       private static final String PROPS_FILE = "org/apache/cocoon/cocoon.properties";
  -    
  +
       static final Properties properties;
  -    
  +
       /**
        * Load the cocoon properties
        */
  @@ -82,9 +82,9 @@
           } catch (IOException ioe) {
               throw new RuntimeException("Cocoon cannot load required properties from " +
PROPS_FILE);
           }
  -        
  +
       }
  -    
  +
       /** The name of this project. */
       public static final String NAME = properties.getProperty("name");
   
  @@ -269,6 +269,12 @@
        * The name of a <code>NotifyingObject</code> in the so called objectModel
<code>Map</code>.
        */
       public static final String NOTIFYING_OBJECT = "notifying-object";
  +
  +    /**
  +     * The default URI to be used when a URI requested refers to
  +     * a directory, e.g. http://localhost:8080/site/
  +     */
  +    public static final String INDEX_URI = "index";
   
       /** The namespace URI for the Error/Exception XML */
       public static final String ERROR_NAMESPACE_URI = "http://apache.org/cocoon/error/"
+ CONF_VERSION;
  
  
  
  1.7       +9 -15     cocoon-2.1/src/java/org/apache/cocoon/bean/CocoonBean.java
  
  Index: CocoonBean.java
  ===================================================================
  RCS file: /home/cvs/cocoon-2.1/src/java/org/apache/cocoon/bean/CocoonBean.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- CocoonBean.java	4 Jun 2003 09:25:53 -0000	1.6
  +++ CocoonBean.java	4 Jun 2003 13:48:50 -0000	1.7
  @@ -105,7 +105,7 @@
    * @author <a href="mailto:stefano@apache.org">Stefano Mazzocchi</a>
    * @author <a href="mailto:nicolaken@apache.org">Nicola Ken Barozzi</a>
    * @author <a href="mailto:vgritsenko@apache.org">Vadim Gritsenko</a>
  - * @author <a href="mailto:uv@upaya.co.uk">Upayavira</a> 
  + * @author <a href="mailto:uv@upaya.co.uk">Upayavira</a>
    * @version CVS $Id$
    */
   public class CocoonBean {
  @@ -133,12 +133,6 @@
        */
       public static final String DEFAULT_CONF_FILE = "cocoon.xconf";
   
  -    /**
  -     * The default URI to be used when a URI requested refers to
  -     * a directory, e.g. http://localhost:8080/site/
  -     */
  -    public static final String INDEX_URI = "index";
  -
       // User Supplied Parameters
       private String contextDir = CocoonBean.DEFAULT_CONTEXT_DIR;
       private String configFile = null;
  @@ -153,7 +147,7 @@
       private String logger = null;
       private String userAgent = DEFAULT_USER_AGENT;
       private String accept = DEFAULT_ACCEPT;
  -    private String defaultFilename = CocoonBean.INDEX_URI;
  +    private String defaultFilename = Constants.INDEX_URI;
       private boolean followLinks = true;
       private boolean precompileOnly = false;
       private boolean confirmExtension = true;
  @@ -497,11 +491,11 @@
       public void addTarget(String type, String root, String sourceURI, String destURI){
           targets.add(new Target(type, root, sourceURI, destURI));
       }
  -  
  +
       public void addTarget(String type, String sourceURI, String destURI){
           targets.add(new Target(type, sourceURI, destURI));
       }
  -  
  +
       public void addTarget(String sourceURI, String destURI){
           targets.add(new Target(sourceURI, destURI));
       }
  @@ -735,7 +729,7 @@
        *   </li>
        * </ul>
        * @param target a <code>Target</code> target to process
  -     * @return a <code>Collection</code> containing all links found, as 
  +     * @return a <code>Collection</code> containing all links found, as
        * Target objects.
        * @exception Exception if an error occurs
        */
  @@ -1210,7 +1204,7 @@
           private String root;
           private String sourceURI;
           private String destURI;
  -        
  +
           public Target(String type, String root, String sourceURI, String destURI){
               this.type = type;
               this.root = root;
  @@ -1233,7 +1227,7 @@
               newURI = newURI.substring(root.length());
               return new Target(this.type, this.root, newURI, this.destURI);
           }
  -        
  +
           public String getFinalURI(String actualSourceURI) throws ProcessingException {
               if (!actualSourceURI.startsWith(root)) {
                   throw new ProcessingException("Derived target does not share same root:
" + actualSourceURI);
  @@ -1277,7 +1271,7 @@
                   return destURI.substring(0,starPos) + actualSourceURI + destURI.substring(starPos+1);
               }
           }
  -   
  +
           public String getSourceURI() {
               return root + sourceURI;
           }
  
  
  

Mime
View raw message