KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > infoglue > cms > applications > structuretool > actions > SimpleStructureXmlAction


1 /*
2  * Created on 2004-nov-28
3  *
4  */

5 package org.infoglue.cms.applications.structuretool.actions;
6
7 import org.infoglue.cms.applications.common.actions.SimpleXmlServiceAction;
8 import org.infoglue.cms.controllers.usecases.structuretool.ViewSiteNodeTreeUCCFactory;
9 import org.infoglue.cms.entities.kernel.BaseEntityVO;
10 import org.infoglue.cms.exception.ConstraintException;
11 import org.infoglue.cms.exception.SystemException;
12 import org.infoglue.cms.security.InfoGluePrincipal;
13 import org.infoglue.cms.treeservice.ss.SiteNodeNodeSupplier;
14
15 import com.frovi.ss.Tree.INodeSupplier;
16
17 /**
18  * @author Stefan Sik
19  * @since 1.4
20  */

21 public class SimpleStructureXmlAction extends SimpleXmlServiceAction {
22
23     /* (non-Javadoc)
24      * @see org.infoglue.cms.applications.common.actions.SimpleXmlServiceAction#getNodeSupplier()
25      */

26     public INodeSupplier getNodeSupplier() throws SystemException {
27         if(this.repositoryId != null && this.repositoryId.intValue() > -1)
28             return new SiteNodeNodeSupplier(getRepositoryId(), this.getInfoGluePrincipal());
29         else
30             return null;
31     }
32     /* (non-Javadoc)
33      * @see org.infoglue.cms.applications.common.actions.SimpleXmlServiceAction#getRootEntityVO(java.lang.Integer, org.infoglue.cms.security.InfoGluePrincipal)
34      */

35     protected BaseEntityVO getRootEntityVO(Integer JavaDoc repositoryId, InfoGluePrincipal principal) throws ConstraintException, SystemException {
36         return ViewSiteNodeTreeUCCFactory.newViewSiteNodeTreeUCC().getRootSiteNode(repositoryId, principal);
37     }
38     
39
40 }
41
Popular Tags