-
Notifications
You must be signed in to change notification settings - Fork 7
converter
h908714124 edited this page Aug 25, 2021
·
16 revisions
The @Parameter and @Option annotations do not have boolean attributes like
required or optional.
Instead, the multiplicity is determined by the return type of the annotated method.
| return type | Multiplicity | Arity (if option) |
|---|---|---|
boolean |
0..1 (optional) |
nullary(*) |
Optional<A> |
0..1 (optional) |
unary |
Optional{Int,Long,Double} |
0..1 (optional) |
unary |
List<A> |
0..* (repeatable) |
unary |
A (exact match) |
1 (required) |
unary |
where A is either one of the
auto types,
or, if the converter attribute is present, the return type of the converter.
(*) only available when the converter attribute is absent