Annotation Interface Extension
@Target({FIELD,METHOD,PARAMETER,TYPE})
@Retention(RUNTIME)
@Repeatable(Extensions.class)
public @interface Extension
A named extension that should be added to the OpenAPI definition.
-
Required Element Summary
-
Optional Element Summary
Modifier and TypeOptional ElementDescriptionboolean
Should the value be parsed into an object/array or other simple type (number, boolean, etc) or left as a simple String.
-
Element Details
-
name
String nameA name for the extension.- Returns:
- an option name for these extensions - will be prefixed with "x-"
-
value
String valueThe extension value. If the value should be parsed into an object or array, then the value should be stringified JSON suitable for parsing by a standard JSON parser.- Returns:
- the actual extension value
-
-
-
parseValue
boolean parseValueShould the value be parsed into an object/array or other simple type (number, boolean, etc) or left as a simple String. If this is true, then the value must be parseable as one of:- JSON object
- JSON array
- number
- boolean
- Returns:
- true if the value should be parsed
- Default:
- false
-