Annotation Interface Requires


@Target(FIELD) @Retention(RUNTIME) public @interface Requires
Indicates that if one field in a value/param object, then one or more other attributes are required.

Note: If the field with the Requires annotation is NOT in the json then the required are not required as long as they have the HasDefaultValue annotation.

  • Required Element Summary

    Required Elements
    Modifier and Type
    Required Element
    Description
    The names of the required fields if this field is present.
  • Element Details

    • value

      String[] value
      The names of the required fields if this field is present.