Annotation Type ApiProperty


@Documented
@Target(FIELD)
@Retention(RUNTIME)
public @interface ApiProperty
  • Optional Element Summary

    Optional Elements
    Modifier and Type Optional Element Description
    boolean canBeNullOrNotSet
    If set and true, the value for this property can be null or unset.
    String value
    If set, this is the property name.
  • Element Details

    • value

      String value
      If set, this is the property name. Otherwise, this defaults to the field name this annotation is on.
      Default:
      ""
    • canBeNullOrNotSet

      boolean canBeNullOrNotSet
      If set and true, the value for this property can be null or unset. All properties with these ambiguous states must have a sibling field that is the same name suffixed with "Specified" that is a boolean. If the boolean is true, the property is considered set to null and if it is false the property is not considered set and won't be serialized.
      Default:
      false