View Javadoc

1   package com.atlassian.sal.api.websudo;
2   
3   import java.lang.annotation.ElementType;
4   import java.lang.annotation.Inherited;
5   import java.lang.annotation.Retention;
6   import java.lang.annotation.RetentionPolicy;
7   import java.lang.annotation.Target;
8   
9   /**
10   * Elements marked with this annotation will require WebSudo protection.
11   * <p/>
12   * This annotation can be applied to:
13   * <ul>
14   * <li>REST resources</li>
15   * </ul>
16   * <p/>
17   * If an element is marked as @WebSudoRequired the host application ensures that it will only be accessed as part of
18   * a WebSudo session if the host application supports WebSudo.
19   * <p/>
20   * <p/>
21   * Annotations can be applied on the package, type (class, interface and enum) and method level.
22   * Annotations on more specific elements (method < type < package) have precedence over annotations applied to more general elements.
23   * E.g. an annotation applied to a method overrides the annotation applied to the whole package.
24   *
25   * @see com.atlassian.sal.api.websudo.WebSudoNotRequired
26   * @since 2.2
27   */
28  @Retention(RetentionPolicy.RUNTIME)
29  @Target({ElementType.PACKAGE, ElementType.METHOD, ElementType.TYPE})
30  @Inherited
31  public @interface WebSudoRequired {
32  }