org.alfresco.repo.model.ml
Class MultilingualDocumentAspect
java.lang.Object
org.alfresco.repo.model.ml.MultilingualDocumentAspect
- All Implemented Interfaces:
- CopyServicePolicies.OnCopyNodePolicy, NodeServicePolicies.BeforeDeleteNodePolicy, NodeServicePolicies.OnUpdatePropertiesPolicy, ClassPolicy, Policy
public class MultilingualDocumentAspect
- extends java.lang.Object
- implements CopyServicePolicies.OnCopyNodePolicy, NodeServicePolicies.BeforeDeleteNodePolicy, NodeServicePolicies.OnUpdatePropertiesPolicy
Class containing behaviour for the multilingual document aspect.
ml document aspect
Nested classes/interfaces inherited from interface org.alfresco.repo.policy.Policy |
Policy.Arg |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MultilingualDocumentAspect
public MultilingualDocumentAspect()
init
public void init()
- Initialise the Multilingual Aspect
Ensures that the
ml document aspect
setPolicyComponent
public void setPolicyComponent(PolicyComponent policyComponent)
- Parameters:
policyComponent
- the policy component to register behaviour with
setMultilingualContentService
public void setMultilingualContentService(MultilingualContentService multilingualContentService)
- Parameters:
multilingualContentService
- the Multilingual Content Service to set
setNodeService
public void setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
- Parameters:
nodeService
- the Node Service to set
getCopyCallback
public CopyBehaviourCallback getCopyCallback(org.alfresco.service.namespace.QName classRef,
CopyDetails copyDetails)
- The copy of a cm:mlDocument can't keep the Multilingual aspect.
- Specified by:
getCopyCallback
in interface CopyServicePolicies.OnCopyNodePolicy
- Parameters:
classRef
- the type or aspect qualified namecopyDetails
- the details of the impending copy
- Returns:
- Returns the
DoNothingCopyBehaviourCallback
- See Also:
CopyServicePolicies
beforeDeleteNode
public void beforeDeleteNode(org.alfresco.service.cmr.repository.NodeRef nodeRef)
- Ensure that the node is properly unhooked from the translation mechanism first.
- Specified by:
beforeDeleteNode
in interface NodeServicePolicies.BeforeDeleteNodePolicy
- Parameters:
nodeRef
- the node reference
onUpdateProperties
public void onUpdateProperties(org.alfresco.service.cmr.repository.NodeRef nodeRef,
java.util.Map before,
java.util.Map after)
- Ensure that the locale is unique inside the mlContainer.
If the locale of a pivot translation is modified, the pivot locale reference of the mlContainer
must be modified too.
- Specified by:
onUpdateProperties
in interface NodeServicePolicies.OnUpdatePropertiesPolicy
- Parameters:
nodeRef
- reference to the updated nodebefore
- the node's properties before the changeafter
- the node's properties after the change
Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.