Annotation Interface PropertyPolicies


@Retention(RUNTIME) @Target({FIELD,METHOD}) public @interface PropertyPolicies
An annotation to declare the policies for property access in the CREST API Descriptor schema elements.
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    boolean
    Whether breaking the declared policy will result in an error from the service.
    The read policy for the property.
    boolean
    true when a field is available, but must be explicitly requested, or false (default) when always returned.
    The write policy for the property.
  • Element Details

    • write

      The write policy for the property. Defaults to WRITABLE.
      Default:
      WRITABLE
    • read

      The read policy for the property. Defaults to USER.
      Default:
      USER
    • errorOnWritePolicyFailure

      boolean errorOnWritePolicyFailure
      Whether breaking the declared policy will result in an error from the service. Only required when write() is not set to WRITABLE. Defaults to false.
      Default:
      false
    • returnOnDemand

      boolean returnOnDemand
      true when a field is available, but must be explicitly requested, or false (default) when always returned.
      Default:
      false