You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lenya.apache.org by eg...@apache.org on 2003/09/04 14:36:37 UTC

cvs commit: cocoon-lenya/src/java/org/apache/lenya/cms/cocoon/acting DefaultCreatorAction.java

egli        2003/09/04 05:36:37

  Modified:    src/java/org/apache/lenya/cms/cocoon/acting
                        DefaultCreatorAction.java
  Log:
  Migrated to the new way of fetching the site tree by way
  of asking the Publication for it instead of creating one
  by passing in the path to the xml tree file.
  
  Revision  Changes    Path
  1.10      +3 -12     cocoon-lenya/src/java/org/apache/lenya/cms/cocoon/acting/DefaultCreatorAction.java
  
  Index: DefaultCreatorAction.java
  ===================================================================
  RCS file: /home/cvs/cocoon-lenya/src/java/org/apache/lenya/cms/cocoon/acting/DefaultCreatorAction.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- DefaultCreatorAction.java	30 Jul 2003 15:30:06 -0000	1.9
  +++ DefaultCreatorAction.java	4 Sep 2003 12:36:37 -0000	1.10
  @@ -96,7 +96,6 @@
    */
   public class DefaultCreatorAction extends AbstractComplementaryConfigurableAction
       implements Configurable {
  -    private String treeAuthoringPath = null;
       private String docsPath = null;
       private String doctypesPath = null;
   
  @@ -110,10 +109,8 @@
       public void configure(Configuration conf) throws ConfigurationException {
           super.configure(conf);
   
  -        treeAuthoringPath = conf.getChild("tree-authoring").getAttribute("href");
           docsPath = conf.getChild("docs").getAttribute("href");
           doctypesPath = conf.getChild("doctypes").getAttribute("href");
  -        getLogger().debug("CONFIGURATION:\nAUTHORING PATH OF TREE=" + treeAuthoringPath);
       }
   
       /**
  @@ -133,8 +130,6 @@
           Parameters parameters) throws Exception {
           Publication publication = PublicationFactory.getPublication(objectModel);
   
  -        getLogger().debug(".act(): PARENT PATH OF SITEMAP: " + publication.getDirectory());
  -
           // Get request object
           Request request = ObjectModelHelper.getRequest(objectModel);
   
  @@ -221,11 +216,7 @@
           creator.init(doctypeConf);
   
           // add a node to the tree
  -        getLogger().debug("invoking DefaultSiteTree(" + publication.getDirectory() +
  -            File.separator + treeAuthoringPath + ")");
  -
  -        DefaultSiteTree siteTree = new DefaultSiteTree(new File(publication.getDirectory(),
  -                    treeAuthoringPath));
  +        DefaultSiteTree siteTree = publication.getSiteTree(Publication.AUTHORING_AREA);
           Label[] labels = new Label[1];
           labels[0] = new Label(childname, null);
           siteTree.addNode(parentid, creator.generateTreeId(childid, childType), labels);
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: lenya-cvs-unsubscribe@cocoon.apache.org
For additional commands, e-mail: lenya-cvs-help@cocoon.apache.org