Annotation Interface CborConfig


Annotation for specifying config properties defined in CborSerializer and CborParser.

Used primarily for specifying bean configuration properties on REST classes and methods.

See Also:
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    Add "_type" properties when needed.
    Maximum allowed wire-declared length for CBOR byte/text strings and array/map element counts when parsing.
    int
    Optional rank for this config.
    Use CBOR semantic tags for dates and other typed values.
  • Element Details

    • addBeanTypes

      Add "_type" properties when needed.

      If "true", then "_type" properties will be added to beans if their type cannot be inferred through reflection.

      • "true"
      • "false" (default)
      Returns:
      The annotation value.
      Default:
      ""
    • useTags

      Use CBOR semantic tags for dates and other typed values.
      • "true"
      • "false" (default)
      Returns:
      The annotation value.
      Default:
      ""
    • maxLength

      Maximum allowed wire-declared length for CBOR byte/text strings and array/map element counts when parsing.

      Guards against malformed or adversarial input where a small payload declares a huge length or element count. Default is "16777216" (16 MiB). A value of "0" or less disables the cap.

      Returns:
      The annotation value.
      Default:
      ""
    • rank

      int rank
      Optional rank for this config.
      Returns:
      The annotation value.
      Default:
      0