Package com.google.inject.internal
Class InjectorShell
java.lang.Object
com.google.inject.internal.InjectorShell
InjectorShell is used by
InternalInjectorCreator
to recursively create a tree of
uninitialized Injector
s. Each InjectorShell corresponds to either the top-level root
injector, or a private child injector.
The root InjectorShell extracts elements from its list of modules and processes these elements
to aggregate data that is used to populate its injector's fields. Child injectors are constructed
similarly, but using PrivateElements
instead of modules.
It is necessary to create the root and child injectors in a single batch because there can be
bidirectional parent <-> child injector dependencies that require the entire tree of injectors to
be initialized together in the InternalInjectorCreator
.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) static class
private static class
private static class
private static class
private static class
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivate
InjectorShell
(List<Element> elements, InjectorImpl injector) -
Method Summary
Modifier and TypeMethodDescriptionprivate static void
bindInjector
(InjectorImpl injector) The Injector is a special case because we allow both parent and child injectors to both have a binding for that key.private static void
bindLogger
(InjectorImpl injector) The Logger is a special case because it knows the injection point of the injected member.private static void
bindStage
(InjectorImpl injector, Stage stage) (package private) InjectorImpl
-
Field Details
-
elements
-
injector
-
-
Constructor Details
-
InjectorShell
-
-
Method Details
-
getInjector
InjectorImpl getInjector() -
getElements
-
bindInjector
The Injector is a special case because we allow both parent and child injectors to both have a binding for that key. -
bindLogger
The Logger is a special case because it knows the injection point of the injected member. It's the only binding that does this. -
bindStage
-