Annotation Interface ScxRoute


@Target({METHOD,TYPE}) @Retention(RUNTIME) public @interface ScxRoute
路由注解 默认会在方法上进行继承 如果想在子类禁用 请使用 NoScxRoute
Version:
0.3.6
Author:
scx567888
  • Element Details

    • value

      String value
      Returns:
      the path
      See Also:
      • Router.route(String)
      Default:
      "THIS IS A SPECIAL NULL VALUE FOR ANNOTATION - DO NOT USE\n"
    • methods

      HttpMethod[] methods
      Returns:
      the path
      See Also:
      • (String)
      Default:
      {}
    • consumes

      String[] consumes
      Returns:
      the path
      See Also:
      • Route.consumes(String)
      Default:
      {}
    • produces

      String[] produces
      Returns:
      the path
      See Also:
      • Route.produces(String)
      Default:
      {}
    • order

      int order
      排序
      Returns:
      a
      Default:
      0
    • ignoreParentUrl

      boolean ignoreParentUrl
      是否忽略类级别上的 ScxRoute 注解所定义的顶级 url
      Returns:
      是否
      Default:
      false
    • useNameAsUrl

      boolean useNameAsUrl
      注意 : 仅当作用于方法时生效 !!! 是否使用方法名称作为 url 路径
      仅当 value 为 "" 时生效
      规则为 获取方法名称 然后转换为 短横线命名法
      如 方法名为 getUserList 则 url 为 /user/get-user-list
      Returns:
      标识
      Default:
      true