批注接口 ConditionalOnResource


@Target({TYPE,METHOD}) @Retention(RUNTIME) @Documented @Conditional(org.springframework.boot.autoconfigure.condition.OnResourceCondition.class) public @interface ConditionalOnResource
@Conditional that only matches when the specified resources are on the classpath.
从以下版本开始:
1.0.0
作者:
Dave Syer
  • 可选元素概要

    可选元素
    修饰符和类型
    可选元素
    说明
    The resources that must be present.
  • 元素详细资料

    • resources

      String[] resources
      The resources that must be present.
      返回:
      the resource paths that must be present.
      默认值:
      {}