Class DefaultPageFactory
- java.lang.Object
-
- org.apache.avalon.framework.logger.AbstractLogEnabled
-
- org.ametys.plugins.repository.jcr.SimpleAmetysObjectFactory
-
- org.ametys.plugins.repository.jcr.DefaultTraversableAmetysObjectFactory
-
- org.ametys.web.repository.page.jcr.DefaultPageFactory
-
- All Implemented Interfaces:
AmetysObjectFactory<SimpleAmetysObject>
,JCRAmetysObjectFactory<SimpleAmetysObject>
,Component
,Configurable
,LogEnabled
,Serviceable
public class DefaultPageFactory extends DefaultTraversableAmetysObjectFactory
AmetysObjectFactory
for creating traversableDefaultPage
.
-
-
Field Summary
-
Fields inherited from class org.ametys.plugins.repository.jcr.SimpleAmetysObjectFactory
_ametysFactoryExtensionPoint, _manager, _nodetype, _repository, _resolver, _scheme
-
-
Constructor Summary
Constructors Constructor Description DefaultPageFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DefaultPage
getAmetysObject(Node node, String parentPath)
Creates aAmetysObject
from a persistent JCR node.PageDataTypeExtensionPoint
getPageDataTypeExtensionPoint()
Retrieves the extension point of page data typesRequest
getRequest()
Get the requestViewParametersManager
getViewParametersManager()
Get the view parameters managerWorkflowProvider
getWorkflowProvider()
Get the workflow provider<A extends AmetysObject>
AresolveAmetysObject(Node node)
Resolves anAmetysObject
from a node.void
service(ServiceManager serviceManager)
-
Methods inherited from class org.ametys.plugins.repository.jcr.DefaultTraversableAmetysObjectFactory
createChild, getChild, getChildren, hasChild
-
Methods inherited from class org.ametys.plugins.repository.jcr.SimpleAmetysObjectFactory
configure, getAmetysObjectById, getAmetysObjectById, getNode, getNodetypes, getParent, getScheme, getWorkspaceNode, hasAmetysObjectForId
-
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
-
-
-
Constructor Detail
-
DefaultPageFactory
public DefaultPageFactory()
-
-
Method Detail
-
service
public void service(ServiceManager serviceManager) throws ServiceException
- Specified by:
service
in interfaceServiceable
- Overrides:
service
in classSimpleAmetysObjectFactory
- Throws:
ServiceException
-
getWorkflowProvider
public WorkflowProvider getWorkflowProvider()
Get the workflow provider- Returns:
- workflow provider
-
getRequest
public Request getRequest()
Get the request- Returns:
- the request
-
getAmetysObject
public DefaultPage getAmetysObject(Node node, String parentPath) throws AmetysRepositoryException
Description copied from interface:JCRAmetysObjectFactory
Creates aAmetysObject
from a persistent JCR node.- Specified by:
getAmetysObject
in interfaceJCRAmetysObjectFactory<SimpleAmetysObject>
- Overrides:
getAmetysObject
in classDefaultTraversableAmetysObjectFactory
- Parameters:
node
- the JCR node to use.parentPath
- the parent Path in the Ametys hierarchy, may benull
if not known yet.- Returns:
- the object.
- Throws:
AmetysRepositoryException
- if an error occurs.
-
resolveAmetysObject
public <A extends AmetysObject> A resolveAmetysObject(Node node) throws AmetysRepositoryException, RepositoryException
Resolves anAmetysObject
from a node.- Type Parameters:
A
- the actual type ofAmetysObject
.- Parameters:
node
- the node.- Returns:
- the
AmetysObject
resolved. - Throws:
AmetysRepositoryException
- if an error occurs.RepositoryException
- if a JCR error occurs.
-
getPageDataTypeExtensionPoint
public PageDataTypeExtensionPoint getPageDataTypeExtensionPoint()
Retrieves the extension point of page data types- Returns:
- the extension point of page data types
-
getViewParametersManager
public ViewParametersManager getViewParametersManager()
Get the view parameters manager- Returns:
- the view parameters manager
-
-