JAL-1645 source formatting and organise imports
[jalview.git] / src / com / github / reinert / jjschema / Attributes.java
1 /*
2  * Copyright (c) 2014, Danilo Reinert (daniloreinert@growbit.com)
3  *
4  * This software is dual-licensed under:
5  *
6  * - the Lesser General Public License (LGPL) version 3.0 or, at your option, any
7  *   later version;
8  * - the Apache Software License (ASL) version 2.0.
9  *
10  * The text of both licenses is available under the src/resources/ directory of
11  * this project (under the names LGPL-3.0.txt and ASL-2.0.txt respectively).
12  *
13  * Direct link to the sources:
14  *
15  * - LGPL 3.0: https://www.gnu.org/licenses/lgpl-3.0.txt
16  * - ASL 2.0: http://www.apache.org/licenses/LICENSE-2.0.txt
17  */
18
19 package com.github.reinert.jjschema;
20
21 import java.lang.annotation.ElementType;
22 import java.lang.annotation.Retention;
23 import java.lang.annotation.RetentionPolicy;
24 import java.lang.annotation.Target;
25
26 /**
27  * Annotation for the attributes of JSON Schema
28  *
29  * @author reinert
30  */
31 @Retention(RetentionPolicy.RUNTIME)
32 @Target({ ElementType.METHOD, ElementType.FIELD, ElementType.TYPE })
33 public @interface Attributes
34 {
35   String $ref() default "";
36
37   String id() default "";
38
39   String title() default "";
40
41   String description() default "";
42
43   long maximum() default -1l;
44
45   boolean exclusiveMaximum() default false;
46
47   int minimum() default -1;
48
49   boolean exclusiveMinimum() default false;
50
51   String pattern() default "";
52
53   boolean required() default false;
54
55   String[] enums() default {};
56
57   int minItems() default 0;
58
59   long maxItems() default -1l;
60
61   boolean uniqueItems() default false;
62
63   int multipleOf() default 0;
64
65   int minLength() default 0;
66
67   long maxLength() default -1l;
68 }