Annotation Interface DynamicParameter


@Target(METHOD) @Retention(RUNTIME) @Documented public @interface DynamicParameter
Note: 自Knife4j 4.0版本起,功能保留,但目前阶段放弃维护此属性值,建议开发者建实体类,后续有迭代在更新
  • 可选元素概要

    可选元素
    修饰符和类型
    可选元素
    说明
    The class of the parameter.
    a single example for non-body type parameters
    Name of the parameter.
    boolean
    Specifies if the parameter is required or not.
    A brief description of the parameter.
  • 元素详细资料

    • name

      String name
      Name of the parameter.
      返回:
      属性名称
      默认值:
      ""
    • value

      String value
      A brief description of the parameter.
      返回:
      属性说明
      默认值:
      ""
    • required

      boolean required
      Specifies if the parameter is required or not.

      Path parameters should always be set as required.

      返回:
      是否必传
      默认值:
      false
    • dataTypeClass

      Class<?> dataTypeClass
      The class of the parameter.

      Overrides dataType if provided.

      返回:
      属性类型
      默认值:
      java.lang.Void.class
    • example

      String example
      a single example for non-body type parameters
      返回:
      属性示例
      从以下版本开始:
      1.5.4
      默认值:
      ""