Package | Description |
---|---|
com.google.inject |
Google Guice (pronounced "juice") is an ultra-lightweight dependency injection framework.
|
com.google.inject.internal |
Guice (sounds like "juice")
|
com.google.inject.multibindings |
Extension for binding multiple instances in a collection; this extension requires
guice-multibindings.jar . |
com.google.inject.spi |
Guice service provider interface
|
com.google.inject.util |
Helper methods for working with Guice.
|
Modifier and Type | Class and Description |
---|---|
class |
AbstractModule
A support class for
Module s which reduces repetition and results in a more readable
configuration. |
class |
PrivateModule
A module whose configuration information is hidden from its environment by default.
|
Modifier and Type | Method and Description |
---|---|
Injector |
Injector.createChildInjector(Module... modules)
Returns a new injector that inherits all state from this injector.
|
static Injector |
Guice.createInjector(Module... modules)
Creates an injector for the given set of modules.
|
static Injector |
Guice.createInjector(Stage stage,
Module... modules)
Creates an injector for the given set of modules, in a given development stage.
|
protected void |
AbstractModule.install(Module module) |
protected void |
PrivateModule.install(Module module) |
void |
Binder.install(Module module)
Uses the given module to configure more bindings.
|
Modifier and Type | Method and Description |
---|---|
Injector |
Injector.createChildInjector(Iterable<? extends Module> modules)
Returns a new injector that inherits all state from this injector.
|
static Injector |
Guice.createInjector(Iterable<? extends Module> modules)
Creates an injector for the given set of modules.
|
static Injector |
Guice.createInjector(Stage stage,
Iterable<? extends Module> modules)
Creates an injector for the given set of modules, in a given development stage.
|
Modifier and Type | Class and Description |
---|---|
class |
ProviderMethodsModule
Creates bindings to methods annotated with @
Provides . |
class |
RealMapBinder<K,V>
The actual mapbinder plays several roles:
|
class |
RealMultibinder<T>
The actual multibinder plays several roles:
|
class |
RealOptionalBinder<T>
The actual OptionalBinder plays several roles.
|
Modifier and Type | Method and Description |
---|---|
static Module |
ProviderMethodsModule.forModule(Module module)
Returns a module which creates bindings for provider methods from the given module.
|
static Module |
ProviderMethodsModule.forModule(Object module,
ModuleAnnotatedMethodScanner scanner)
Returns a module which creates bindings methods in the module that match the scanner.
|
static Module |
ProviderMethodsModule.forObject(Object object)
Returns a module which creates bindings for provider methods from the given object.
|
Modifier and Type | Method and Description |
---|---|
static Module |
ProviderMethodsModule.forModule(Module module)
Returns a module which creates bindings for provider methods from the given module.
|
Modifier and Type | Method and Description |
---|---|
InternalInjectorCreator |
InternalInjectorCreator.addModules(Iterable<? extends Module> modules) |
Modifier and Type | Method and Description |
---|---|
static Module |
MultibindingsScanner.asModule()
Deprecated.
This functionality is now installed by default. All references/installations can be
eliminated.
|
Modifier and Type | Method and Description |
---|---|
static Module |
Elements.getModule(Iterable<? extends Element> elements)
Returns the module composed of
elements . |
Modifier and Type | Method and Description |
---|---|
static List<Element> |
Elements.getElements(Module... modules)
Records the elements executed by
modules . |
static List<Element> |
Elements.getElements(Stage stage,
Module... modules)
Records the elements executed by
modules . |
Modifier and Type | Method and Description |
---|---|
static List<Element> |
Elements.getElements(Iterable<? extends Module> modules)
Records the elements executed by
modules . |
static List<Element> |
Elements.getElements(Stage stage,
Iterable<? extends Module> modules)
Records the elements executed by
modules . |
Modifier and Type | Field and Description |
---|---|
static Module |
Modules.EMPTY_MODULE |
Modifier and Type | Method and Description |
---|---|
static Module |
Modules.combine(Iterable<? extends Module> modules)
Returns a new module that installs all of
modules . |
static Module |
Modules.combine(Module... modules)
Returns a new module that installs all of
modules . |
Module |
Modules.OverriddenModuleBuilder.with(Iterable<? extends Module> overrides)
See the EDSL example at
override() . |
Module |
Modules.OverriddenModuleBuilder.with(Module... overrides)
See the EDSL example at
override() . |
Modifier and Type | Method and Description |
---|---|
static Module |
Modules.combine(Module... modules)
Returns a new module that installs all of
modules . |
static Modules.OverriddenModuleBuilder |
Modules.override(Module... modules)
Returns a builder that creates a module that overlays override modules over the given modules.
|
Module |
Modules.OverriddenModuleBuilder.with(Module... overrides)
See the EDSL example at
override() . |
Modifier and Type | Method and Description |
---|---|
static Module |
Modules.combine(Iterable<? extends Module> modules)
Returns a new module that installs all of
modules . |
static Modules.OverriddenModuleBuilder |
Modules.override(Iterable<? extends Module> modules)
Returns a builder that creates a module that overlays override modules over the given modules.
|
Module |
Modules.OverriddenModuleBuilder.with(Iterable<? extends Module> overrides)
See the EDSL example at
override() . |
Copyright © 2006–2018 Google, Inc.. All rights reserved.