Class ConstructorBindingImpl<T>

    • Method Detail

      • create

        static <T> ConstructorBindingImpl<T> create​(InjectorImpl injector,
                                                    Key<T> key,
                                                    InjectionPoint constructorInjector,
                                                    java.lang.Object source,
                                                    Scoping scoping,
                                                    Errors errors,
                                                    boolean failIfNotLinked,
                                                    boolean atInjectRequired)
                                             throws ErrorsException
        Parameters:
        constructorInjector - the constructor to use, or null to use the default.
        failIfNotLinked - true if this ConstructorBindingImpl's InternalFactory should only succeed if retrieved from a linked binding
        Throws:
        ErrorsException
      • isInitialized

        boolean isInitialized()
        True if this binding has been initialized and is ready for use.
      • getInternalConstructor

        InjectionPoint getInternalConstructor()
        Returns an injection point that can be used to clean up the constructor store.
      • getInternalDependencies

        java.util.Set<Dependency<?>> getInternalDependencies()
        Returns a set of dependencies that can be iterated over to clean up stray JIT bindings.
      • acceptTargetVisitor

        public <V> V acceptTargetVisitor​(BindingTargetVisitor<? super T,​V> visitor)
        Description copied from interface: Binding
        Accepts a target visitor. Invokes the visitor method specific to this binding's target.
        Specified by:
        acceptTargetVisitor in interface Binding<T>
        Parameters:
        visitor - to call back on
      • getInjectableMembers

        public java.util.Set<InjectionPoint> getInjectableMembers()
        Description copied from interface: ConstructorBinding
        Returns all instance method and field injection points on type.
        Specified by:
        getInjectableMembers in interface ConstructorBinding<T>
        Returns:
        a possibly empty set of injection points. The set has a specified iteration order. All fields are returned and then all methods. Within the fields, supertype fields are returned before subtype fields. Similarly, supertype methods are returned before subtype methods.
      • getMethodInterceptors

        public java.util.Map<java.lang.reflect.Method,​java.util.List<org.aopalliance.intercept.MethodInterceptor>> getMethodInterceptors()
        Description copied from interface: ConstructorBinding
        Returns the interceptors applied to each method, in the order that they will be applied.
        Specified by:
        getMethodInterceptors in interface ConstructorBinding<T>
        Returns:
        a possibly empty map
      • getDependencies

        public java.util.Set<Dependency<?>> getDependencies()
        Description copied from interface: HasDependencies
        Returns the known dependencies for this type. If this has dependencies whose values are not known statically, a dependency for the Injector will be included in the returned set.
        Specified by:
        getDependencies in interface HasDependencies
        Returns:
        a possibly empty set
      • applyTo

        public void applyTo​(Binder binder)
        Description copied from interface: Element
        Writes this module element to the given binder (optional operation).
        Specified by:
        applyTo in interface Element
        Parameters:
        binder - to apply configuration element to
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object