Annotation Type RequiresDomain
This annotation is used to indicate that a given class has the specified
DomainRequirement
. This is used to automatically discover the
extent of existing requirements, so that the user can specify the necessary
requirements from a sufficiently complete list presented in the UI.
For Example (URI):
If a plugin only supports https/ssh URIs, we might annotate:
@RequiresDomain(value = SecureURIRequirement.class)
Even though only one of the two may be necessary, it is sufficient to only
surface the options HTTPS/SSH in the specification UI.
For Example (OAuth2):
This is much more important for less constrained spaces than URI schemes,
especially when the options are harder to type options, e.g. OAuth2 scopes.
In this case, a plugin might annotate:
@RequiresDomain(value = OAuth2ScopesABandC.class)
Even though the task they end up configuring may only require scopes
"A" and "B".- See Also:
-
Required Element Summary
-
Element Details
-
value
Class<? extends com.cloudbees.plugins.credentials.domains.DomainRequirement> valueThe class ofDomainRequirement
to which the annotated class adheres.
-