Class ActivityFactory
java.lang.Object
org.apache.avalon.framework.logger.AbstractLogEnabled
org.ametys.plugins.repository.jcr.SimpleAmetysObjectFactory
org.ametys.plugins.repository.activities.ActivityFactory
- All Implemented Interfaces:
AmetysObjectFactory<SimpleAmetysObject>
,JCRAmetysObjectFactory<SimpleAmetysObject>
,Component
,Configurable
,LogEnabled
,Serviceable
AmetysObject factory associated with
Activity
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
data name for the author of the activitystatic final String
data name for the date of the activitystatic final String
Avalon Role for activity data typesstatic final String
activity node type name.static final String
data name for the type of the event represented by the activityFields inherited from class org.ametys.plugins.repository.jcr.SimpleAmetysObjectFactory
_ametysFactoryExtensionPoint, _manager, _nodetype, _repository, _resolver, _scheme
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionRetrieve anActivityType
based on a event idgetAmetysObject
(javax.jcr.Node node, String parentPath) Creates aAmetysObject
from a persistent JCR node.Retrieves the extension point with available modelItem types forActivity
void
service
(ServiceManager serviceManager) 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
-
Field Details
-
MODEL_ITEM_TYPE_EXTENSION_ROLE
Avalon Role for activity data types -
NODE_TYPE
activity node type name.- See Also:
-
DATE
data name for the date of the activity- See Also:
-
TYPE
data name for the type of the event represented by the activity- See Also:
-
AUTHOR
data name for the author of the activity- See Also:
-
-
Constructor Details
-
ActivityFactory
public ActivityFactory()
-
-
Method Details
-
service
- Specified by:
service
in interfaceServiceable
- Overrides:
service
in classSimpleAmetysObjectFactory
- Throws:
ServiceException
-
getAmetysObject
public Activity getAmetysObject(javax.jcr.Node node, String parentPath) throws AmetysRepositoryException, javax.jcr.RepositoryException Description copied from interface:JCRAmetysObjectFactory
Creates aAmetysObject
from a persistent JCR node.- Specified by:
getAmetysObject
in interfaceJCRAmetysObjectFactory<SimpleAmetysObject>
- Overrides:
getAmetysObject
in classSimpleAmetysObjectFactory
- 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.javax.jcr.RepositoryException
- if a JCR error occurs.
-
getElementTypesExtensionPoint
Retrieves the extension point with available modelItem types forActivity
- Returns:
- the extension point with available modelItem types for
Activity
-
getActivityTypeFromId
Retrieve anActivityType
based on a event id- Parameters:
id
- the event id- Returns:
- the activity type
-