@Target(value={METHOD,FIELD})
@Retention(value=RUNTIME)
public @interface ApiModelProperty
Modifier and Type | Optional Element and Description |
---|---|
java.lang.String |
access
Allows for filtering a property from the API documentation.
|
java.lang.String |
allowableValues
Limits the acceptable values for this parameter.
|
boolean |
allowEmptyValue
Allows passing an empty value
|
java.lang.String |
dataType
The data type of the parameter.
|
java.lang.String |
example
A sample value for the property.
|
Extension[] |
extensions |
boolean |
hidden
Allows a model property to be hidden in the Swagger model definition.
|
java.lang.String |
name
Allows overriding the name of the property.
|
java.lang.String |
notes
Currently not in use.
|
int |
position
Allows explicitly ordering the property in the model.
|
boolean |
readOnly
Allows a model property to be designated as read only.
|
java.lang.String |
reference
Specifies a reference to the corresponding type definition, overrides any other metadata specified
|
boolean |
required
Specifies if the parameter is required or not.
|
java.lang.String |
value
A brief description of this property.
|
public abstract java.lang.String value
public abstract java.lang.String name
public abstract java.lang.String allowableValues
There are three ways to describe the allowable values:
first, second, third
.range[1, 5]
, range(1, 5)
, range[1, 5)
.range[1, infinity]
means the
minimum allowable value of this parameter is 1.public abstract java.lang.String access
public abstract java.lang.String dataType
This can be the class name or a primitive. The value will override the data type as read from the class property.
public abstract boolean required
public abstract int position
public abstract boolean hidden
public abstract boolean readOnly
public abstract java.lang.String reference
public abstract boolean allowEmptyValue
public abstract Extension[] extensions
Copyright © 2018. All Rights Reserved.