@Retention(value=RUNTIME) @Target(value=METHOD) public @interface AllowedValues
The AllowedValues
method annotation defines the list of valid values for a
JobParameter
or RequestParameter
. The annotation can only be defined
on a setXXX
method which has either the JobParameter
or RequestParameter
annotations.
The list of allowed values are encoded as strings. The string values will be
converted to the data type of the parameter on the setXXX
method.
The list of allowed values is returned with the parameter descriptions in the business application specifications web services.
The list of allowed values is used to Construct a new select list field on the job submission form. If the parameter is not required the select field will include "-" to indicate the null (not selected) value.
The following code fragment shows an example of using the API.
@AllowedValues(value = { "MD5", "SHA" }) @JobParameter @RequestParameter public void setAlgorithmName(final String algorithmName) { this.algorithmName = algorithmName; }
public abstract String[] value
Copyright © 2008–2017 Province of British Columbia. All rights reserved.