Package com.google.inject.internal
Class ConstructorInjectorStore
java.lang.Object
com.google.inject.internal.ConstructorInjectorStore
Constructor injectors by type.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final FailableCache<InjectionPoint,
ConstructorInjector<?>> private final InjectorImpl
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate <T> ConstructorInjector<T>
createConstructor
(InjectionPoint injectionPoint, Errors errors) get
(InjectionPoint constructorInjector, Errors errors) Returns a new complete constructor injector with injection listeners registered.(package private) boolean
remove
(InjectionPoint ip) Purges an injection point from the cache.
-
Field Details
-
injector
-
cache
-
-
Constructor Details
-
ConstructorInjectorStore
ConstructorInjectorStore(InjectorImpl injector)
-
-
Method Details
-
get
public ConstructorInjector<?> get(InjectionPoint constructorInjector, Errors errors) throws ErrorsException Returns a new complete constructor injector with injection listeners registered.- Throws:
ErrorsException
-
remove
Purges an injection point from the cache. Use this only if the cache is not actually valid and needs to be purged. (See issue 319 and ImplicitBindingTest#testCircularJitBindingsLeaveNoResidue and #testInstancesRequestingProvidersForThemselvesWithChildInjectors for examples of when this is necessary.)Returns true if the injector for that point was stored in the cache, false otherwise.
-
createConstructor
private <T> ConstructorInjector<T> createConstructor(InjectionPoint injectionPoint, Errors errors) throws ErrorsException - Throws:
ErrorsException
-