Class Qualifiers

    • Constructor Summary

      Constructors 
      Constructor Description
      Qualifiers()  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      Qualifiers createCopy()
      Returns a copy of this configuration object.
      java.util.Set<java.lang.annotation.Annotation> findFor​(java.lang.reflect.AnnotatedElement... elements)
      Returns the set of qualifying annotations on the given elements.
      private static java.util.Set<java.lang.annotation.Annotation> getQualifiers​(java.lang.reflect.AnnotatedElement... elements)  
      <ELEM extends java.lang.reflect.AnnotatedElement & java.lang.reflect.Type>
      QualifiedType<?>
      qualifiedTypeOf​(ELEM type)  
      void setRegistry​(ConfigRegistry registry)
      The registry will inject itself into the configuration object.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • QUALIFIER_CACHE

        private static final ConfigCache<java.lang.reflect.AnnotatedElement[],​java.util.Set<java.lang.annotation.Annotation>> QUALIFIER_CACHE
      • QUALIFIED_TYPE_CACHE

        private static final ConfigCache<java.lang.reflect.AnnotatedElement,​QualifiedType<?>> QUALIFIED_TYPE_CACHE
    • Constructor Detail

      • Qualifiers

        public Qualifiers()
    • Method Detail

      • setRegistry

        public void setRegistry​(ConfigRegistry registry)
        Description copied from interface: JdbiConfig
        The registry will inject itself into the configuration object. This can be useful if you need to look up dependencies. You will get a new registry after being copied.
        Specified by:
        setRegistry in interface JdbiConfig<Qualifiers>
        Parameters:
        registry - the registry that owns this configuration object
      • qualifiedTypeOf

        public <ELEM extends java.lang.reflect.AnnotatedElement & java.lang.reflect.Type> QualifiedType<?> qualifiedTypeOf​(ELEM type)
      • findFor

        public java.util.Set<java.lang.annotation.Annotation> findFor​(java.lang.reflect.AnnotatedElement... elements)
        Returns the set of qualifying annotations on the given elements.
        Parameters:
        elements - the annotated elements. Null elements are ignored.
        Returns:
        the set of qualifying annotations on the given elements.
      • getQualifiers

        private static java.util.Set<java.lang.annotation.Annotation> getQualifiers​(java.lang.reflect.AnnotatedElement... elements)
      • createCopy

        public Qualifiers createCopy()
        Description copied from interface: JdbiConfig
        Returns a copy of this configuration object. Changes to the copy should not modify the original, and vice-versa.
        Specified by:
        createCopy in interface JdbiConfig<Qualifiers>
        Returns:
        a copy of this configuration object.