org.elasticsearch.common.inject
Interface Module
- All Known Implementing Classes:
- AbstractModule, AnalysisModule, BlobStoreGatewayModule, BloomCacheModule, ClientTransportActionModule, ClientTransportModule, ClusterModule, ClusterNameModule, DeletionPolicyModule, DiscoveryModule, DummyRiverModule, EngineModule, EnvironmentModule, FacetModule, FieldDataCacheModule, FilterCacheModule, FsGatewayModule, FsIndexGatewayModule, GatewayModule, HttpServerModule, IdCacheModule, IndexAliasesServiceModule, IndexCacheModule, IndexEngineModule, IndexGatewayModule, IndexModule, IndexNameModule, IndexPluginsModule, IndexQueryParserModule, IndexSettingsModule, IndexShardGatewayModule, IndexShardModule, IndexStoreModule, IndicesAnalysisModule, IndicesModule, IndicesQueriesModule, JmxModule, LocalDiscoveryModule, LocalGatewayModule, LocalIndexGatewayModule, LocalNodeIdModule, LocalTransportModule, MapperServiceModule, MemoryIndexStoreModule, MergePolicyModule, MergeSchedulerModule, MmapFsIndexStoreModule, MonitorModule, NettyHttpServerTransportModule, NettyTransportModule, NetworkModule, NioFsIndexStoreModule, NodeCacheModule, NodeClientModule, NodeEnvironmentModule, NodeModule, NoneGatewayModule, NoneIndexGatewayModule, OperationRoutingModule, PercolatorModule, PlainOperationRoutingModule, PluginsModule, PrivateModule, ProviderMethodsModule, QueryParserCacheModule, RamIndexStoreModule, RestActionModule, RestModule, RiverModule, RiverNameModule, RiversModule, RiversPluginsModule, RobinEngineModule, RobinIndexEngineModule, ScriptModule, SearchModule, SettingsModule, ShardAllocationModule, ShardsPluginsModule, SimilarityModule, SimpleFsIndexStoreModule, StoreModule, ThreadPoolModule, TranslogModule, TransportActionModule, TransportFacetModule, TransportModule, TransportSearchModule, ZenDiscoveryModule
public interface Module
A module contributes configuration information, typically interface
bindings, which will be used to create an Injector
. A Guice-based
application is ultimately composed of little more than a set of
Module
s and some bootstrapping code.
Your Module classes can use a more streamlined syntax by extending
AbstractModule
rather than implementing this interface directly.
In addition to the bindings configured via configure(org.elasticsearch.common.inject.Binder)
, bindings
will be created for all methods annotated with @Provides
.
Use scope and binding annotations on these methods to configure the
bindings.
Method Summary |
void |
configure(Binder binder)
Contributes bindings and other configurations for this module to binder . |
configure
void configure(Binder binder)
- Contributes bindings and other configurations for this module to
binder
.
Do not invoke this method directly to install submodules. Instead use
Binder.install(Module)
, which ensures that provider methods
are
discovered.