Skip to content

Commit 9488c67

Browse files
committed
updated tags, formatting
1 parent 5cd3c76 commit 9488c67

File tree

5 files changed

+183
-178
lines changed

5 files changed

+183
-178
lines changed

modules/swagger-annotations/src/main/java/com/wordnik/swagger/annotations/Api.java

Lines changed: 82 additions & 82 deletions
Original file line numberDiff line numberDiff line change
@@ -33,95 +33,95 @@
3333
@Retention(RetentionPolicy.RUNTIME)
3434
@Inherited
3535
public @interface Api {
36-
/**
37-
* The 'path' that is going to be used to host the API Declaration of the
38-
* resource.
39-
* <p/>
40-
* For JAX-RS resources, this would normally have the same value as the {@code @Path}
41-
* on the resource, but can be any other value as well. It will serve as the path
42-
* where the documentation is hosted.
43-
* <p/>
44-
* For Servlets, this path has to be the path serving the Servlet.
45-
* <p/>
46-
* If the value isn't preceded with a slash, one would be added to it.
47-
*/
48-
String value();
36+
/**
37+
* The 'path' that is going to be used to host the API Declaration of the
38+
* resource.
39+
* <p/>
40+
* For JAX-RS resources, this would normally have the same value as the {@code @Path}
41+
* on the resource, but can be any other value as well. It will serve as the path
42+
* where the documentation is hosted.
43+
* <p/>
44+
* For Servlets, this path has to be the path serving the Servlet.
45+
* <p/>
46+
* If the value isn't preceded with a slash, one would be added to it.
47+
*/
48+
String value();
4949

50-
/**
51-
* A list of tags for API documentation control.
52-
* Tags can be used for logical grouping of operations by resources or any other qualifier.
53-
*
54-
* @since 1.5.2
55-
*/
56-
Tag[] tags() default @Tag(value = "", description = "");
50+
/**
51+
* A list of tags for API documentation control.
52+
* Tags can be used for logical grouping of operations by resources or any other qualifier.
53+
*
54+
* @since 1.5.2
55+
*/
56+
Tag[] tags() default @Tag(value = "", description = "");
5757

58-
/**
59-
* Corresponds to the `description` field of the Resource Listing API operation.
60-
* <p/>
61-
* This should be a short description of the resource.
62-
*/
63-
String description() default "";
58+
/**
59+
* Corresponds to the `description` field of the Resource Listing API operation.
60+
* <p/>
61+
* This should be a short description of the resource.
62+
*/
63+
String description() default "";
6464

65-
/**
66-
* Corresponds to the `basePath` field of the API Declaration.
67-
* <p/>
68-
* The `basePath` is derived automatically by Swagger. This property allows
69-
* overriding the default value if needed.
70-
*
71-
* @since 1.3.7
72-
*/
73-
String basePath() default "";
65+
/**
66+
* Corresponds to the `basePath` field of the API Declaration.
67+
* <p/>
68+
* The `basePath` is derived automatically by Swagger. This property allows
69+
* overriding the default value if needed.
70+
*
71+
* @since 1.3.7
72+
*/
73+
String basePath() default "";
7474

75-
/**
76-
* Optional explicit ordering of this API resource in the Resource Listing.
77-
*/
78-
int position() default 0;
75+
/**
76+
* Optional explicit ordering of this API resource in the Resource Listing.
77+
*/
78+
int position() default 0;
7979

80-
/**
81-
* Corresponds to the `produces` field of the API Declaration.
82-
* <p/>
83-
* Takes in comma-separated values of content types.
84-
* For example, "application/json, application/xml" would suggest this API Resource
85-
* generates JSON and XML output.
86-
* <p/>
87-
* For JAX-RS resources, this would automatically take the value of the {@code @Produces}
88-
* annotation if such exists. It can also be used to override the {@code @Produces} values
89-
* for the Swagger documentation.
90-
*/
91-
String produces() default "";
80+
/**
81+
* Corresponds to the `produces` field of the API Declaration.
82+
* <p/>
83+
* Takes in comma-separated values of content types.
84+
* For example, "application/json, application/xml" would suggest this API Resource
85+
* generates JSON and XML output.
86+
* <p/>
87+
* For JAX-RS resources, this would automatically take the value of the {@code @Produces}
88+
* annotation if such exists. It can also be used to override the {@code @Produces} values
89+
* for the Swagger documentation.
90+
*/
91+
String produces() default "";
9292

93-
/**
94-
* Corresponds to the `consumes` field of the API Declaration.
95-
* <p/>
96-
* Takes in comma-separated values of content types.
97-
* For example, "application/json, application/xml" would suggest this API Resource
98-
* accepts JSON and XML input.
99-
* <p/>
100-
* For JAX-RS resources, this would automatically take the value of the {@code @Consumes}
101-
* annotation if such exists. It can also be used to override the {@code @Consumes} values
102-
* for the Swagger documentation.
103-
*/
104-
String consumes() default "";
93+
/**
94+
* Corresponds to the `consumes` field of the API Declaration.
95+
* <p/>
96+
* Takes in comma-separated values of content types.
97+
* For example, "application/json, application/xml" would suggest this API Resource
98+
* accepts JSON and XML input.
99+
* <p/>
100+
* For JAX-RS resources, this would automatically take the value of the {@code @Consumes}
101+
* annotation if such exists. It can also be used to override the {@code @Consumes} values
102+
* for the Swagger documentation.
103+
*/
104+
String consumes() default "";
105105

106-
/**
107-
* This property is currently not in use.
108-
*/
109-
String protocols() default "";
106+
/**
107+
* This property is currently not in use.
108+
*/
109+
String protocols() default "";
110110

111-
/**
112-
* Corresponds to the `authorizations` field of the API Declaration.
113-
* <p/>
114-
* Takes in a list of the required authorizations for this API Resource.
115-
* This may be overridden by specific operations.
116-
*
117-
* @see Authorization
118-
*/
119-
Authorization[] authorizations() default @Authorization(value = "", type = "");
111+
/**
112+
* Corresponds to the `authorizations` field of the API Declaration.
113+
* <p/>
114+
* Takes in a list of the required authorizations for this API Resource.
115+
* This may be overridden by specific operations.
116+
*
117+
* @see Authorization
118+
*/
119+
Authorization[] authorizations() default @Authorization(value = "", type = "");
120120

121-
/**
122-
* Hides the api.
123-
*
124-
* @since 1.3.8
125-
*/
126-
boolean hidden() default false;
121+
/**
122+
* Hides the api.
123+
*
124+
* @since 1.3.8
125+
*/
126+
boolean hidden() default false;
127127
}

modules/swagger-annotations/src/main/java/com/wordnik/swagger/annotations/ApiImplicitParam.java

Lines changed: 64 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -35,76 +35,76 @@
3535
@Retention(RetentionPolicy.RUNTIME)
3636
@Inherited
3737
public @interface ApiImplicitParam {
38-
/**
39-
* Name of the parameter.
40-
* <p/>
41-
* For proper Swagger functionality, follow these rules when naming your parameters based on {@link #paramType()}:
42-
* <ol>
43-
* <li>If {@code paramType} is "path", the name should be the associated section in the path.</li>
44-
* <li>If {@code paramType} is "body", the name should be "body".</li>
45-
* <li>For all other cases, the name should be the parameter name as your application expects to accept.</li>
46-
* </ol>
47-
*
48-
* @see #paramType()
49-
*/
50-
String name() default "";
38+
/**
39+
* Name of the parameter.
40+
* <p/>
41+
* For proper Swagger functionality, follow these rules when naming your parameters based on {@link #paramType()}:
42+
* <ol>
43+
* <li>If {@code paramType} is "path", the name should be the associated section in the path.</li>
44+
* <li>If {@code paramType} is "body", the name should be "body".</li>
45+
* <li>For all other cases, the name should be the parameter name as your application expects to accept.</li>
46+
* </ol>
47+
*
48+
* @see #paramType()
49+
*/
50+
String name() default "";
5151

52-
/**
53-
* A brief description of the parameter.
54-
*/
55-
String value() default "";
52+
/**
53+
* A brief description of the parameter.
54+
*/
55+
String value() default "";
5656

57-
/**
58-
* Describes the default value for the parameter.
59-
*/
60-
String defaultValue() default "";
57+
/**
58+
* Describes the default value for the parameter.
59+
*/
60+
String defaultValue() default "";
6161

62-
/**
63-
* Limits the acceptable values for this parameter.
64-
* <p/>
65-
* There are three ways to describe the allowable values:
66-
* <ol>
67-
* <li>To set a list of values, provide a comma-separated list surrounded by square brackets.
68-
* For example: {@code [first, second, third]}.</li>
69-
* <li>To set a range of values, start the value with "range", and surrounding by square
70-
* brackets include the minimum and maximum values. For example: {@code range[1, 5]}.</li>
71-
* <li>To set a minimum/maximum value, use the same format for range but use "infinity"
72-
* or "-infinity" as the second value. For example, {@code range[1, infinity]} means the
73-
* minimum allowable value of this parameter is 1.</li>
74-
* </ol>
75-
*/
76-
String allowableValues() default "";
62+
/**
63+
* Limits the acceptable values for this parameter.
64+
* <p/>
65+
* There are three ways to describe the allowable values:
66+
* <ol>
67+
* <li>To set a list of values, provide a comma-separated list surrounded by square brackets.
68+
* For example: {@code [first, second, third]}.</li>
69+
* <li>To set a range of values, start the value with "range", and surrounding by square
70+
* brackets include the minimum and maximum values. For example: {@code range[1, 5]}.</li>
71+
* <li>To set a minimum/maximum value, use the same format for range but use "infinity"
72+
* or "-infinity" as the second value. For example, {@code range[1, infinity]} means the
73+
* minimum allowable value of this parameter is 1.</li>
74+
* </ol>
75+
*/
76+
String allowableValues() default "";
7777

78-
/**
79-
* Specifies if the parameter is required or not.
80-
* <p/>
81-
* Path parameters should always be set as required.
82-
*/
83-
boolean required() default false;
78+
/**
79+
* Specifies if the parameter is required or not.
80+
* <p/>
81+
* Path parameters should always be set as required.
82+
*/
83+
boolean required() default false;
8484

85-
/**
86-
* Allows for filtering a parameter from the API documentation.
87-
*
88-
* @see com.wordnik.swagger.core.filter.SwaggerSpecFilter
89-
*/
90-
String access() default "";
85+
/**
86+
* Allows for filtering a parameter from the API documentation.
87+
*
88+
* @see com.wordnik.swagger.core.filter.SwaggerSpecFilter
89+
*/
90+
String access() default "";
9191

92-
/**
93-
* Specifies whether the parameter can accept multiple comma-separated values.
94-
*/
95-
boolean allowMultiple() default false;
92+
/**
93+
* Specifies whether the parameter can accept multiple comma-separated values.
94+
*/
95+
boolean allowMultiple() default false;
9696

97-
/**
98-
* The data type of the parameter.
99-
* <p/>
100-
* This can be the class name or a primitive.
101-
*/
102-
String dataType() default "";
97+
/**
98+
* The data type of the parameter.
99+
* <p/>
100+
* This can be the class name or a primitive.
101+
*/
102+
String dataType() default "";
103103

104-
/**
105-
* The parameter type of the parameter.
106-
*
107-
* Valid values are {@code path}, {@code query}, {@code body}, {@code header} or {@code form}.
108-
*/
109-
String paramType() default "";
104+
/**
105+
* The parameter type of the parameter.
106+
*
107+
* Valid values are {@code path}, {@code query}, {@code body}, {@code header} or {@code form}.
108+
*/
109+
String paramType() default "";
110110
}

modules/swagger-annotations/src/main/java/com/wordnik/swagger/annotations/ApiImplicitParams.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@
2727
@Retention(RetentionPolicy.RUNTIME)
2828
@Inherited
2929
public @interface ApiImplicitParams {
30-
/**
31-
* A list of {@link com.wordnik.swagger.annotations.ApiImplicitParam}s available to the API operation.
32-
*/
33-
ApiImplicitParam[] value();
30+
/**
31+
* A list of {@link com.wordnik.swagger.annotations.ApiImplicitParam}s available to the API operation.
32+
*/
33+
ApiImplicitParam[] value();
3434
}

modules/swagger-annotations/src/main/java/com/wordnik/swagger/annotations/ApiModel.java

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -28,33 +28,33 @@
2828
@Retention(RetentionPolicy.RUNTIME)
2929
@Inherited
3030
public @interface ApiModel {
31-
/**
32-
* Provide an alternative name for the model.
33-
* <p/>
34-
* By default, the class name is used.
35-
*/
36-
String value() default "";
31+
/**
32+
* Provide an alternative name for the model.
33+
* <p/>
34+
* By default, the class name is used.
35+
*/
36+
String value() default "";
3737

38-
/**
39-
* Provide a longer description of the class.
40-
*/
41-
String description() default "";
38+
/**
39+
* Provide a longer description of the class.
40+
*/
41+
String description() default "";
4242

43-
/**
44-
* Provide a superclass for the model to allow describing inheritance.
45-
*/
46-
Class<?> parent() default Void.class;
43+
/**
44+
* Provide a superclass for the model to allow describing inheritance.
45+
*/
46+
Class<?> parent() default Void.class;
4747

48-
/**
49-
* Supports model inheritance and polymorphism.
50-
* <p/>
51-
* This is the name of the field used as a discriminator. Based on this field,
52-
* it would be possible to assert which sub type needs to be used.
53-
*/
54-
String discriminator() default "";
48+
/**
49+
* Supports model inheritance and polymorphism.
50+
* <p/>
51+
* This is the name of the field used as a discriminator. Based on this field,
52+
* it would be possible to assert which sub type needs to be used.
53+
*/
54+
String discriminator() default "";
5555

56-
/**
57-
* An array of the sub types inheriting from this model.
58-
*/
59-
Class<?>[] subTypes() default {};
56+
/**
57+
* An array of the sub types inheriting from this model.
58+
*/
59+
Class<?>[] subTypes() default {};
6060
}

0 commit comments

Comments
 (0)