Afterburner will discover the implementations of this interface using the Java extension mechanism.
You will have to register the an implementation by placing a text file:
META-INF/services/com.airhacks.afterburner.injection.PresenterFactory
containing the fully qualified name of the implementation.
| Modifier and Type | Method and Description |
|---|---|
| public static PresenterFactory | Returns: the discovered implementations of PresenterFactory using thejava. mechanism
|
| public void | injectMembers(Object
the object to inject members into instance, Function<String, Object> a cache of already instantiated and initialized instances injectionContext)Populate the given object. |
| public < the type of the presenter T> T | Returns: a fully initialized presenter with injected dependencies.presenter class containing the default constructor clazz, Function<String, Object> a cache of already instantiated and initialized instances injectionContext)This method method replaces the standard afterburner dependency injection. |
| discover | back to summary |
|---|---|
public static PresenterFactory discover()
| |
| injectMembers | back to summary |
|---|---|
| public void injectMembers(Object instance, Function<String, Object> injectionContext) Populate the given object.
For example, set all fields annotated with | |
| instantiatePresenter | back to summary |
|---|---|
| public <T> T instantiatePresenter(Class<T> clazz, Function<String, Object> injectionContext) This method method replaces the standard afterburner dependency injection. | |