类 TypeFilterFactories

java.lang.Object
spring.turbo.bean.classpath.TypeFilterFactories

public final class TypeFilterFactories extends Object
本类包含一系列静态方法创建TypeFilter的实例
从以下版本开始:
1.0.0
作者:
应卓
另请参阅:
  • 方法概要

    修饰符和类型
    方法
    说明
    static org.springframework.core.type.filter.TypeFilter
    all(org.springframework.core.type.filter.TypeFilter... filters)
    被装饰的所有TypeFilter任意一个返回false,整体返回false,否则返回true
    static org.springframework.core.type.filter.TypeFilter
    总是返回false的TypeFilter
    static org.springframework.core.type.filter.TypeFilter
    总是返回true的TypeFilter
    static org.springframework.core.type.filter.TypeFilter
    any(org.springframework.core.type.filter.TypeFilter... filters)
    被装饰的所有TypeFilter任意一个返回true,整体返回true,否则返回false
    static org.springframework.core.type.filter.TypeFilter
    assignable(Class<?> targetType)
    通过可赋值性过滤类型
    static org.springframework.core.type.filter.TypeFilter
    通过类名过滤类型
    static org.springframework.core.type.filter.TypeFilter
    fullyQualifiedNameEquals(String className, boolean ignoreCase)
    通过类名过滤类型
    static org.springframework.core.type.filter.TypeFilter
    通过正则表达式匹配FQN过滤类型
    static org.springframework.core.type.filter.TypeFilter
    hasAnnotation(Class<? extends Annotation> annotationType)
    通过元注释来过滤类型
    static org.springframework.core.type.filter.TypeFilter
    hasAnnotation(Class<? extends Annotation> annotationType, boolean considerMetaAnnotations, boolean considerInterfaces)
    通过元注释来过滤类型
    static org.springframework.core.type.filter.TypeFilter
    过滤有父类型的类型
    static org.springframework.core.type.filter.TypeFilter
    implementsInterface(Class<?> interfaceType)
    过滤实现了指定接口的类型
    static org.springframework.core.type.filter.TypeFilter
    过滤抽象的类型。
    static org.springframework.core.type.filter.TypeFilter
    过滤是元注释的类型
    static org.springframework.core.type.filter.TypeFilter
    过滤具象的类型
    static org.springframework.core.type.filter.TypeFilter
    过滤是Final的类型
    static org.springframework.core.type.filter.TypeFilter
    过滤是顶级类型或静态内部类
    static org.springframework.core.type.filter.TypeFilter
    过滤内部类的类型
    static org.springframework.core.type.filter.TypeFilter
    过滤是接口的类型
    static org.springframework.core.type.filter.TypeFilter
    过滤不是元注释的类型
    static org.springframework.core.type.filter.TypeFilter
    过滤是不是Final的类型
    static org.springframework.core.type.filter.TypeFilter
    过滤非内部类型
    static org.springframework.core.type.filter.TypeFilter
    过滤是不是接口的类型
    static org.springframework.core.type.filter.TypeFilter
    过滤非package-info
    static org.springframework.core.type.filter.TypeFilter
    过滤 package-info
    static org.springframework.core.type.filter.TypeFilter
    not(org.springframework.core.type.filter.TypeFilter f)
    逻辑取反
    static org.springframework.core.type.filter.TypeFilter
    notImplementsInterface(Class<?> interfaceType)
    过滤没有实现指定接口的类型

    从类继承的方法 java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • 方法详细资料

    • hasAnnotation

      public static org.springframework.core.type.filter.TypeFilter hasAnnotation(Class<? extends Annotation> annotationType)
      通过元注释来过滤类型
      参数:
      annotationType - 元注释类型
      返回:
      TypeFilter的实例
    • hasAnnotation

      public static org.springframework.core.type.filter.TypeFilter hasAnnotation(Class<? extends Annotation> annotationType, boolean considerMetaAnnotations, boolean considerInterfaces)
      通过元注释来过滤类型
      参数:
      annotationType - 元注释类型
      considerMetaAnnotations - 考虑Meta元注释的情形
      considerInterfaces - 考虑元注释在接口上而不仅仅在实现类上的情形
      返回:
      TypeFilter的实例
    • assignable

      public static org.springframework.core.type.filter.TypeFilter assignable(Class<?> targetType)
      通过可赋值性过滤类型
      参数:
      targetType - 赋值目标类型
      返回:
      TypeFilter的实例
    • fullyQualifiedNameEquals

      public static org.springframework.core.type.filter.TypeFilter fullyQualifiedNameEquals(String className)
      通过类名过滤类型
      参数:
      className - 指定的类型
      返回:
      TypeFilter的实例
    • fullyQualifiedNameEquals

      public static org.springframework.core.type.filter.TypeFilter fullyQualifiedNameEquals(String className, boolean ignoreCase)
      通过类名过滤类型
      参数:
      className - 指定的类型
      ignoreCase - 是否忽略大小写
      返回:
      TypeFilter的实例
    • fullyQualifiedNameMatch

      public static org.springframework.core.type.filter.TypeFilter fullyQualifiedNameMatch(String regex)
      通过正则表达式匹配FQN过滤类型
      参数:
      regex - 正则表达式
      返回:
      TypeFilter的实例
    • isInterface

      public static org.springframework.core.type.filter.TypeFilter isInterface()
      过滤是接口的类型
      返回:
      TypeFilter的实例
      另请参阅:
    • isNotInterface

      public static org.springframework.core.type.filter.TypeFilter isNotInterface()
      过滤是不是接口的类型
      返回:
      TypeFilter的实例
      另请参阅:
    • isAbstract

      public static org.springframework.core.type.filter.TypeFilter isAbstract()
      过滤抽象的类型。包含接口和抽象类。
      返回:
      TypeFilter的实例
      另请参阅:
    • isConcrete

      public static org.springframework.core.type.filter.TypeFilter isConcrete()
      过滤具象的类型
      返回:
      TypeFilter的实例
      另请参阅:
    • isAnnotation

      public static org.springframework.core.type.filter.TypeFilter isAnnotation()
      过滤是元注释的类型
      返回:
      TypeFilter的实例
      另请参阅:
    • isNotAnnotation

      public static org.springframework.core.type.filter.TypeFilter isNotAnnotation()
      过滤不是元注释的类型
      返回:
      TypeFilter实例
      另请参阅:
    • isFinal

      public static org.springframework.core.type.filter.TypeFilter isFinal()
      过滤是Final的类型
      返回:
      TypeFilter的实例
      另请参阅:
    • isNotFinal

      public static org.springframework.core.type.filter.TypeFilter isNotFinal()
      过滤是不是Final的类型
      返回:
      TypeFilter的实例
      另请参阅:
    • isIndependent

      public static org.springframework.core.type.filter.TypeFilter isIndependent()
      过滤是顶级类型或静态内部类
      返回:
      TypeFilter的实例
    • hasSuperClass

      public static org.springframework.core.type.filter.TypeFilter hasSuperClass()
      过滤有父类型的类型
      返回:
      TypeFilter的实例
    • isInnerClass

      public static org.springframework.core.type.filter.TypeFilter isInnerClass()
      过滤内部类的类型
      返回:
      TypeFilter的实例
      另请参阅:
    • isNotInnerClass

      public static org.springframework.core.type.filter.TypeFilter isNotInnerClass()
      过滤非内部类型
      返回:
      TypeFilter的实例
      另请参阅:
    • implementsInterface

      public static org.springframework.core.type.filter.TypeFilter implementsInterface(Class<?> interfaceType)
      过滤实现了指定接口的类型
      参数:
      interfaceType - 指定接口
      返回:
      TypeFilter的实例
      另请参阅:
    • notImplementsInterface

      public static org.springframework.core.type.filter.TypeFilter notImplementsInterface(Class<?> interfaceType)
      过滤没有实现指定接口的类型
      参数:
      interfaceType - 指定接口
      返回:
      TypeFilter的实例
      另请参阅:
    • isPackageInfo

      public static org.springframework.core.type.filter.TypeFilter isPackageInfo()
      过滤 package-info
      返回:
      TypeFilter的实例
      另请参阅:
    • isNotPackageInfo

      public static org.springframework.core.type.filter.TypeFilter isNotPackageInfo()
      过滤非package-info
      返回:
      TypeFilter的实例
      另请参阅:
    • not

      public static org.springframework.core.type.filter.TypeFilter not(org.springframework.core.type.filter.TypeFilter f)
      逻辑取反
      参数:
      f - 代理的TypeFilter实例
      返回:
      装饰后的TypeFilter实例
    • any

      public static org.springframework.core.type.filter.TypeFilter any(org.springframework.core.type.filter.TypeFilter... filters)
      被装饰的所有TypeFilter任意一个返回true,整体返回true,否则返回false
      参数:
      filters - 代理的TypeFilter实例
      返回:
      装饰后的TypeFilter实例
    • all

      public static org.springframework.core.type.filter.TypeFilter all(org.springframework.core.type.filter.TypeFilter... filters)
      被装饰的所有TypeFilter任意一个返回false,整体返回false,否则返回true
      参数:
      filters - 代理的TypeFilter实例
      返回:
      装饰后的TypeFilter实例
    • alwaysTrue

      public static org.springframework.core.type.filter.TypeFilter alwaysTrue()
      总是返回true的TypeFilter
      返回:
      TypeFilter实例
    • alwaysFalse

      public static org.springframework.core.type.filter.TypeFilter alwaysFalse()
      总是返回false的TypeFilter
      返回:
      TypeFilter实例