Provides. Use the scope and
binding annotations on the provider method to configure the binding.
| Modifier and Type | Class and Description |
|---|---|
| private static class | |
| private static class |
| Modifier and Type | Field and Description |
|---|---|
| private final Object | |
| private final ModuleAnnotatedMethodScanner | |
| private final boolean | |
| private final TypeLiteral |
| Access | Constructor and Description |
|---|---|
| private | ProviderMethodsModule(Object delegate, boolean skipFastClassGeneration, ModuleAnnotatedMethodScanner scanner)
|
| Modifier and Type | Method and Description |
|---|---|
| public void | configure(Binder binder)
Implements com. binder.
|
| private <T> ProviderMethod | |
| public boolean | equals(Object
the reference object with which to compare. o)Overrides java. |
| public static Module | |
| public static Module | forModule(Object module, ModuleAnnotatedMethodScanner scanner)
Returns a module which creates bindings methods in the module that match the scanner. |
| public static Module | |
| private static Module | |
| private Annotation | getAnnotation(Binder binder, Method method)
Returns the annotation that is claimed by the scanner, or null if there is none. |
| public Class | |
| pack-priv <T> Key | |
| public List | |
| public ModuleAnnotatedMethodScanner | |
| public int | |
| public boolean | |
| private boolean | |
| private static boolean |
| delegate | back to summary |
|---|---|
| private final Object delegate | |
| scanner | back to summary |
|---|---|
| private final ModuleAnnotatedMethodScanner scanner | |
| skipFastClassGeneration | back to summary |
|---|---|
| private final boolean skipFastClassGeneration | |
| typeLiteral | back to summary |
|---|---|
| private final TypeLiteral<?> typeLiteral | |
| ProviderMethodsModule | back to summary |
|---|---|
| private ProviderMethodsModule(Object delegate, boolean skipFastClassGeneration, ModuleAnnotatedMethodScanner scanner) | |
| configure | back to summary |
|---|---|
| public void configure(Binder binder) Implements com. Doc from com. Contributes bindings and other configurations for this module to Do not invoke this method directly to install submodules. Instead use
| |
| createProviderMethod | back to summary |
|---|---|
| private <T> ProviderMethod | |
| equals | back to summary |
|---|---|
| public boolean equals(Object o) Overrides java. Doc from java. Indicates whether some other object is "equal to" this one.
The
An equivalence relation partitions the elements it operates on into equivalence classes; all the members of an equivalence class are equal to each other. Members of an equivalence class are substitutable for each other, at least for some purposes. | |
| forModule | back to summary |
|---|---|
| public static Module forModule(Module module) Returns a module which creates bindings for provider methods from the given module. | |
| forModule | back to summary |
|---|---|
| public static Module forModule(Object module, ModuleAnnotatedMethodScanner scanner) Returns a module which creates bindings methods in the module that match the scanner. | |
| forObject | back to summary |
|---|---|
| public static Module forObject(Object object) Returns a module which creates bindings for provider methods from the given object. This is useful notably for GIN This will skip bytecode generation for provider methods, since it is assumed that callers are only interested in Module metadata. | |
| forObject | back to summary |
|---|---|
| private static Module forObject(Object object, boolean skipFastClassGeneration, ModuleAnnotatedMethodScanner scanner) | |
| getAnnotation | back to summary |
|---|---|
| private Annotation getAnnotation(Binder binder, Method method) Returns the annotation that is claimed by the scanner, or null if there is none. | |
| getDelegateModuleClass | back to summary |
|---|---|
| public Class | |
| getKey | back to summary |
|---|---|
| pack-priv <T> Key | |
| getProviderMethods | back to summary |
|---|---|
| public List | |
| getScanner | back to summary |
|---|---|
| public ModuleAnnotatedMethodScanner getScanner() | |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Doc from java. Returns a hash code value for this object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
| |
| isScanningBuiltInProvidesMethods | back to summary |
|---|---|
| public boolean isScanningBuiltInProvidesMethods() Is it scanning the built-in @Provides* methods. | |
| isStaticModule | back to summary |
|---|---|
| private boolean isStaticModule() | |
| overrides | back to summary |
|---|---|
| private static boolean overrides(Method a, Method b) Returns true if a overrides b, assumes that the signatures match | |
| Modifier and Type | Field and Description |
|---|---|
| pack-priv final Annotation | |
| pack-priv final Method |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| annotation | back to summary |
|---|---|
| pack-priv final Annotation annotation | |
| method | back to summary |
|---|---|
| pack-priv final Method method | |
| MethodAndAnnotation | back to summary |
|---|---|
| pack-priv MethodAndAnnotation(Method method, Annotation annotation) | |
| Modifier and Type | Field and Description |
|---|---|
| pack-priv final int | |
| pack-priv final String | |
| pack-priv final Class |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | equals(Object
the reference object with which to compare. obj)Overrides java. |
| public int |
| hashCode | back to summary |
|---|---|
| pack-priv final int hashCode | |
| name | back to summary |
|---|---|
| pack-priv final String name | |
| parameters | back to summary |
|---|---|
| pack-priv final Class<?>[] parameters | |
| Signature | back to summary |
|---|---|
| pack-priv Signature(TypeLiteral<?> typeLiteral, Method method) | |
| equals | back to summary |
|---|---|
| public boolean equals(Object obj) Overrides java. Doc from java. Indicates whether some other object is "equal to" this one.
The
An equivalence relation partitions the elements it operates on into equivalence classes; all the members of an equivalence class are equal to each other. Members of an equivalence class are substitutable for each other, at least for some purposes. | |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Doc from java. Returns a hash code value for this object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
| |