Class AdapterInjectionSupport
java.lang.Object
com.google.inject.AbstractModule
org.eclipse.gef.common.adapt.inject.AdapterInjectionSupport
- All Implemented Interfaces:
Module
A configuration module that can be installed (via
Binder.install(Module)) to enable support for injection of adapters
into IAdaptables. The adapters that are to be injected can be
configured through respective adapter (map) bindings (see AdapterMap
). Injection is performed on all IAdaptables that are eligible for
adapter injection (see InjectAdapters).-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumTheAdapterInjectionSupport.LoggingModespecifies if binding-related information and warning messages should be printed. -
Constructor Summary
ConstructorsConstructorDescriptionConstructs a newAdapterInjectionSupportinAdapterInjectionSupport.LoggingMode.DEVELOPMENTmode, i.e. binding-related information, warning, and error messages will be printed.Constructs a newAdapterInjectionSupportand specifies theAdapterInjectionSupport.LoggingModeto use. -
Method Summary
Modifier and TypeMethodDescriptionprotected voidBinds anAdaptableTypeListener(viaAbstractModule.bindListener(Matcher, TypeListener)) and ensures it gets properly injected (AbstractModule.requestInjection(Object)).Methods inherited from class com.google.inject.AbstractModule
addError, addError, addError, bind, bind, bind, bindConstant, binder, bindInterceptor, bindListener, bindListener, bindScope, configure, convertToTypes, currentStage, getMembersInjector, getMembersInjector, getProvider, getProvider, install, requestInjection, requestInjection, requestStaticInjection, requireBinding, requireBinding
-
Constructor Details
-
AdapterInjectionSupport
public AdapterInjectionSupport()Constructs a newAdapterInjectionSupportinAdapterInjectionSupport.LoggingMode.DEVELOPMENTmode, i.e. binding-related information, warning, and error messages will be printed. -
AdapterInjectionSupport
Constructs a newAdapterInjectionSupportand specifies theAdapterInjectionSupport.LoggingModeto use. If inAdapterInjectionSupport.LoggingMode.DEVELOPMENTmode, binding-related information, warning, and error messages will be printed. If inAdapterInjectionSupport.LoggingMode.PRODUCTIONmode, only error messages will be printed, and information and warning messages will be suppressed.- Parameters:
loggingMode- TheAdapterInjectionSupport.LoggingModeto use.
-
-
Method Details
-
configure
protected void configure()Binds anAdaptableTypeListener(viaAbstractModule.bindListener(Matcher, TypeListener)) and ensures it gets properly injected (AbstractModule.requestInjection(Object)).- Overrides:
configurein classAbstractModule
-