com.github.dynamicextensionsalfresco.behaviours.annotations.AssociationPolicy Maven / Gradle / Ivy
Show all versions of annotations Show documentation
package com.github.dynamicextensionsalfresco.behaviours.annotations;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
/**
* Indicates a method is a Class-level Policy.
*
* This annotation should only be applied to {@link org.alfresco.repo.policy.ClassPolicy} interface methods.
*
* @author Laurens Fridael
*
*/
@Target({ ElementType.METHOD })
@Retention(RetentionPolicy.RUNTIME)
public @interface AssociationPolicy {
/**
* The QNames of the types or aspects to apply the Policy to. Can be specified in prefix format (
* cm:content
) or fully-qualified format (
* {http://www.alfresco.org/model/content/1.0}content
).
*
* If no value is specified, the Policy is applied to all types and aspects.
*
* @return
*/
String[] value() default {};
/**
* The QName of the association to apply the Policy to. Can be specified in prefix format ( or fully-qualified
* format.
*
* If no value is specified, the Policy is applied to all associations. If an association has been specified, the
* class name must also be specified. It is invalid to specify only an assocation.
*
* @return
*/
String association() default "";
/**
* Indicates when to trigger the Behaviour.
*
* @return
*/
Event event() default Event.INHERITED_OR_ALL;
}