Package org.alfresco.repo.model.ml
Class EmptyTranslationAspect
- java.lang.Object
-
- org.alfresco.repo.model.ml.EmptyTranslationAspect
-
- All Implemented Interfaces:
ContentServicePolicies.OnContentUpdatePolicy,CopyServicePolicies.OnCopyNodePolicy,ClassPolicy,Policy
public class EmptyTranslationAspect extends java.lang.Object implements CopyServicePolicies.OnCopyNodePolicy, ContentServicePolicies.OnContentUpdatePolicy
Class containing behaviour for the multilingual empty translation aspect. An empty translation is a document's properties translation. This kind of node doesn't have a content.ml empty document aspect- Author:
- Yannick Pignot
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.alfresco.repo.policy.Policy
Policy.Arg
-
-
Field Summary
-
Fields inherited from interface org.alfresco.repo.content.ContentServicePolicies.OnContentUpdatePolicy
QNAME
-
Fields inherited from interface org.alfresco.repo.copy.CopyServicePolicies.OnCopyNodePolicy
ARG_0, ARG_1, QNAME
-
-
Constructor Summary
Constructors Constructor Description EmptyTranslationAspect()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CopyBehaviourCallbackgetCopyCallback(org.alfresco.service.namespace.QName classRef, CopyDetails copyDetails)Called for all types and aspects before copying a node.voidinit()Initialise the Multilingual Empty Translation AspectvoidonContentUpdate(org.alfresco.service.cmr.repository.NodeRef nodeRef, boolean newContent)If a content is added to a cm:mlEmptyTranslation, remove this aspect.voidonCopyNode(org.alfresco.service.namespace.QName classRef, org.alfresco.service.cmr.repository.NodeRef sourceNodeRef, org.alfresco.service.cmr.repository.StoreRef destinationStoreRef, boolean copyToNewNode, PolicyScope copyDetails)Copy a cm:mlEmptyTranslation is not permit.voidsetNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)voidsetPolicyComponent(PolicyComponent policyComponent)
-
-
-
Method Detail
-
init
public void init()
Initialise the Multilingual Empty Translation AspectEnsures that the
ml empty document aspect
-
setPolicyComponent
public void setPolicyComponent(PolicyComponent policyComponent)
- Parameters:
policyComponent- the policy component to register behaviour with
-
setNodeService
public void setNodeService(org.alfresco.service.cmr.repository.NodeService nodeService)
- Parameters:
nodeService- the Node Service to set
-
onCopyNode
public void onCopyNode(org.alfresco.service.namespace.QName classRef, org.alfresco.service.cmr.repository.NodeRef sourceNodeRef, org.alfresco.service.cmr.repository.StoreRef destinationStoreRef, boolean copyToNewNode, PolicyScope copyDetails)Copy a cm:mlEmptyTranslation is not permit.
-
onContentUpdate
public void onContentUpdate(org.alfresco.service.cmr.repository.NodeRef nodeRef, boolean newContent)If a content is added to a cm:mlEmptyTranslation, remove this aspect.- Specified by:
onContentUpdatein interfaceContentServicePolicies.OnContentUpdatePolicy- Parameters:
nodeRef- the node reference
-
getCopyCallback
public CopyBehaviourCallback getCopyCallback(org.alfresco.service.namespace.QName classRef, CopyDetails copyDetails)
Description copied from interface:CopyServicePolicies.OnCopyNodePolicyCalled for all types and aspects before copying a node.- Specified by:
getCopyCallbackin interfaceCopyServicePolicies.OnCopyNodePolicy- Parameters:
classRef- the type or aspect qualified namecopyDetails- the details of the impending copy- Returns:
- Returns CopyBehaviourCallback
- See Also:
CopyServicePolicies
-
-