@Retention(value=RUNTIME) public @interface RamlParameter
Annotation to describe a parameter.
| Modifier and Type | Required Element and Description |
|---|---|
String |
name
The name of the parameter.
|
String |
type
The type of parameter.
|
| Modifier and Type | Optional Element and Description |
|---|---|
String[] |
allowedValues
The list of allowed values as a string list.
|
Class<? extends Enum> |
allowedValuesEnum
The enum the allowed values for the parameter are derived from.
|
String |
defaultValue
The default for the parameter if not supplied.
|
String |
description
The description of the parameter
|
String |
displayName
The display name of the parameter.
|
String |
example
The example of the parameter.
|
long |
maximum
The maximum value the parameter is allowed to have.
|
long |
minimum
The minimum value the parameter is allowed to have.
|
boolean |
multiple
Flag if the parameter accepts multiple values.
|
String |
pattern
The regular expression pattern the parameter must adhere to.
|
boolean |
required
Flag if the parameter is required or not.
|
public abstract String name
The name of the parameter.
public abstract String type
The type of parameter.
If describing an array parameter, define the item type here.
Must align with the Allowable Built-In Types
public abstract String displayName
The display name of the parameter.
public abstract String description
The description of the parameter
public abstract boolean required
Flag if the parameter is required or not.
public abstract boolean multiple
Flag if the parameter accepts multiple values.
public abstract String[] allowedValues
The list of allowed values as a string list.
If the allowedValuesEnum() property is defined, this is ignored.
public abstract String example
The example of the parameter.
public abstract String pattern
The regular expression pattern the parameter must adhere to.
Only suitable for string-based parameters.
public abstract String defaultValue
The default for the parameter if not supplied.
Copyright © 2020. All rights reserved.