eXo JCR :: Component :: Extension Service 1.15.1-CP01

org.exoplatform.services.jcr.ext.hierarchy.impl
Class NodeHierarchyCreatorImpl

java.lang.Object
  extended by org.exoplatform.services.jcr.ext.hierarchy.impl.NodeHierarchyCreatorImpl
All Implemented Interfaces:
NodeHierarchyCreator, org.picocontainer.Startable

public class NodeHierarchyCreatorImpl
extends Object
implements NodeHierarchyCreator, org.picocontainer.Startable

Created by The eXo Platform SAS Author : Dang Van Minh minh.dang@exoplatform.com Nov 15, 2007 2:21:57 PM


Constructor Summary
NodeHierarchyCreatorImpl(RepositoryService jcrService, DataDistributionManager dataDistributionManager, org.exoplatform.container.xml.InitParams params)
           
NodeHierarchyCreatorImpl(RepositoryService jcrService, org.exoplatform.container.xml.InitParams params)
           
 
Method Summary
 void addPlugin(org.exoplatform.container.component.ComponentPlugin plugin)
          Registers a new plugins
 String getJcrPath(String alias)
          Gets the JCR path corresponding to the given alias
 javax.jcr.Node getPublicApplicationNode(SessionProvider sessionProvider)
          Gets the JCR node corresponding to the root node of the public applications
 javax.jcr.Node getUserApplicationNode(SessionProvider sessionProvider, String userName)
          Gets the JCR node corresponding to the root node of the user's applications
 javax.jcr.Node getUserNode(SessionProvider sessionProvider, String userName)
          Gets the JCR node corresponding to the root node of the user workspace
 void init()
          Initialize the current repository thanks to all the registered plugins
 void init(String repository)
          Initialize the given repository thanks to all the registered plugins
 void removeUserNode(SessionProvider sessionProvider, String userName)
          Remove the JCR node corresponding to the root node of the user workspace
 void start()
          
 void stop()
          
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NodeHierarchyCreatorImpl

public NodeHierarchyCreatorImpl(RepositoryService jcrService,
                                org.exoplatform.container.xml.InitParams params)

NodeHierarchyCreatorImpl

public NodeHierarchyCreatorImpl(RepositoryService jcrService,
                                DataDistributionManager dataDistributionManager,
                                org.exoplatform.container.xml.InitParams params)
Method Detail

start

public void start()

Specified by:
start in interface org.picocontainer.Startable

stop

public void stop()

Specified by:
stop in interface org.picocontainer.Startable

init

public void init(String repository)
          throws Exception
Initialize the given repository thanks to all the registered plugins

Specified by:
init in interface NodeHierarchyCreator
Parameters:
repository - the repository to initialize
Throws:
Exception - if an exception occurs

init

public void init()
          throws Exception
Initialize the current repository thanks to all the registered plugins

Specified by:
init in interface NodeHierarchyCreator
Throws:
Exception - if an exception occurs

getUserApplicationNode

public javax.jcr.Node getUserApplicationNode(SessionProvider sessionProvider,
                                             String userName)
                                      throws Exception
Gets the JCR node corresponding to the root node of the user's applications

Specified by:
getUserApplicationNode in interface NodeHierarchyCreator
Parameters:
sessionProvider - the session provider to use to get the root node
userName - the user name for which we want to find the root node of his applications
Returns:
the root node of the user's applications of the given user
Throws:
Exception - if an exception occurs

getPublicApplicationNode

public javax.jcr.Node getPublicApplicationNode(SessionProvider sessionProvider)
                                        throws Exception
Gets the JCR node corresponding to the root node of the public applications

Specified by:
getPublicApplicationNode in interface NodeHierarchyCreator
Parameters:
sessionProvider - the session provider to use to get the root node
Returns:
the root node of the public applications
Throws:
Exception - if an exception occurs

getUserNode

public javax.jcr.Node getUserNode(SessionProvider sessionProvider,
                                  String userName)
                           throws Exception
Gets the JCR node corresponding to the root node of the user workspace

Specified by:
getUserNode in interface NodeHierarchyCreator
Parameters:
sessionProvider - the session provider to use to get the root node
userName - the user name for which we want to find the root node of his workspace
Returns:
the root node of the workspace of the given user
Throws:
Exception - if an exception occurs

removeUserNode

public void removeUserNode(SessionProvider sessionProvider,
                           String userName)
                    throws Exception
Remove the JCR node corresponding to the root node of the user workspace

Specified by:
removeUserNode in interface NodeHierarchyCreator
Parameters:
sessionProvider - the session provider to use to remove the root node
userName - the user name for which we want to remove the root node of his workspace
Throws:
Exception - if an exception occurs

getJcrPath

public String getJcrPath(String alias)
Gets the JCR path corresponding to the given alias

Specified by:
getJcrPath in interface NodeHierarchyCreator
Parameters:
alias - the alias of the path to retrieve
Returns:
the corresponding JCR path

addPlugin

public void addPlugin(org.exoplatform.container.component.ComponentPlugin plugin)
Registers a new plugins

Specified by:
addPlugin in interface NodeHierarchyCreator
Parameters:
plugin - the plugin to register

eXo JCR :: Component :: Extension Service 1.15.1-CP01

Copyright © 2013 eXo Platform SAS. All Rights Reserved.