1 package com.bradmcevoy.property;
2
3 import com.bradmcevoy.property.PropertySource.PropertyAccessibility;
4 import java.lang.annotation.ElementType;
5 import java.lang.annotation.Retention;
6 import java.lang.annotation.RetentionPolicy;
7 import java.lang.annotation.Target;
8
9 /**
10 * Annotation type to identify classes to be accessible by
11 * BeanPropertySource
12 *
13 * This allows them to have their properties read from and written to
14 * by PROPFIND and PROPPATCH.
15 *
16 * @author brad
17 */
18 @Target(ElementType.TYPE)
19 @Retention(RetentionPolicy.RUNTIME)
20 public @interface BeanPropertyResource {
21
22 /**
23 * Default property which is the namespace uri for the properties
24 * on this resource
25 *
26 * E.g. http://mycompany.com/ns/example
27 *
28 * @return - the namespace uri
29 */
30 String value();
31 /**
32 *
33 * @return - true allows the resource to be updatable
34 */
35 boolean writable() default true;
36
37 /**
38 * If true, indicates that properties on the resource should be accessible
39 * unless otherwise specified
40 *
41 * @return
42 */
43 boolean enableByDefault() default true;
44 }