org.alfresco.repo.forum
Class ForumPostBehaviours
java.lang.Object
org.alfresco.repo.forum.ForumPostBehaviours
- All Implemented Interfaces:
- NodeServicePolicies.BeforeDeleteNodePolicy, NodeServicePolicies.OnCreateNodePolicy, NodeServicePolicies.OnUpdatePropertiesPolicy, ClassPolicy, Policy
public class ForumPostBehaviours
- extends java.lang.Object
- implements NodeServicePolicies.OnCreateNodePolicy, NodeServicePolicies.BeforeDeleteNodePolicy, NodeServicePolicies.OnUpdatePropertiesPolicy
This class registers behaviours for the fm:post
content type.
These behaviours maintain the correct value for the comment count rollup property
.
- Since:
- 4.0
Nested classes/interfaces inherited from interface org.alfresco.repo.policy.Policy |
Policy.Arg |
Method Summary |
void |
beforeDeleteNode(org.alfresco.service.cmr.repository.NodeRef nodeRef)
Called before a node is deleted. |
void |
init()
Initialise method |
void |
onCreateNode(org.alfresco.service.cmr.repository.ChildAssociationRef childAssocRef)
Called when a new node has been created. |
void |
onUpdateProperties(org.alfresco.service.cmr.repository.NodeRef commentsRollupNode,
java.util.Map before,
java.util.Map after)
Called after a node's properties have been changed. |
void |
setCommentService(CommentService commentService)
|
void |
setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
|
void |
setPolicyComponent(PolicyComponent policyComponent)
|
void |
setRawNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
COUNT_TRIGGER_VALUE
public static final int COUNT_TRIGGER_VALUE
- See Also:
- Constant Field Values
ForumPostBehaviours
public ForumPostBehaviours()
setPolicyComponent
public void setPolicyComponent(PolicyComponent policyComponent)
setCommentService
public void setCommentService(CommentService commentService)
setNodeService
public void setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
setRawNodeService
public void setRawNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
init
public void init()
- Initialise method
onUpdateProperties
public void onUpdateProperties(org.alfresco.service.cmr.repository.NodeRef commentsRollupNode,
java.util.Map before,
java.util.Map after)
- Description copied from interface:
NodeServicePolicies.OnUpdatePropertiesPolicy
- Called after a node's properties have been changed.
- Specified by:
onUpdateProperties
in interface NodeServicePolicies.OnUpdatePropertiesPolicy
- Parameters:
commentsRollupNode
- reference to the updated nodebefore
- the node's properties before the changeafter
- the node's properties after the change
onCreateNode
public void onCreateNode(org.alfresco.service.cmr.repository.ChildAssociationRef childAssocRef)
- Description copied from interface:
NodeServicePolicies.OnCreateNodePolicy
- Called when a new node has been created.
- Specified by:
onCreateNode
in interface NodeServicePolicies.OnCreateNodePolicy
- Parameters:
childAssocRef
- the created child association reference
beforeDeleteNode
public void beforeDeleteNode(org.alfresco.service.cmr.repository.NodeRef nodeRef)
- Description copied from interface:
NodeServicePolicies.BeforeDeleteNodePolicy
- Called before a node is deleted.
- Specified by:
beforeDeleteNode
in interface NodeServicePolicies.BeforeDeleteNodePolicy
- Parameters:
nodeRef
- the node reference
Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.