Class CheckedProviderMethod<T>
java.lang.Object
com.google.inject.throwingproviders.CheckedProviderMethod<T>
- All Implemented Interfaces:
HasDependencies,CheckedProvider<T>
A provider that invokes a method and returns its result.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final Class<? extends CheckedProvider>private final com.google.common.collect.ImmutableSet<Dependency<?>>private final List<TypeLiteral<?>>private final booleanprivate final Objectprivate final Methodprivate final Class<? extends Annotation>private final boolean -
Constructor Summary
ConstructorsConstructorDescriptionCheckedProviderMethod(Key<T> key, Method method, Object instance, com.google.common.collect.ImmutableSet<Dependency<?>> dependencies, List<Provider<?>> parameterProviders, Class<? extends Annotation> scopeAnnotation, Class<? extends CheckedProvider> checkedProvider, List<TypeLiteral<?>> exceptionTypes, boolean scopeExceptions) -
Method Summary
Modifier and TypeMethodDescription(package private) voidget()Set<Dependency<?>>Returns the known dependencies for this type.toString()
-
Field Details
-
key
-
scopeAnnotation
-
instance
-
method
-
dependencies
-
parameterProviders
-
exposed
private final boolean exposed -
checkedProvider
-
exceptionTypes
-
scopeExceptions
private final boolean scopeExceptions
-
-
Constructor Details
-
CheckedProviderMethod
CheckedProviderMethod(Key<T> key, Method method, Object instance, com.google.common.collect.ImmutableSet<Dependency<?>> dependencies, List<Provider<?>> parameterProviders, Class<? extends Annotation> scopeAnnotation, Class<? extends CheckedProvider> checkedProvider, List<TypeLiteral<?>> exceptionTypes, boolean scopeExceptions)
-
-
Method Details
-
configure
-
get
- Specified by:
getin interfaceCheckedProvider<T>- Throws:
Exception
-
getDependencies
Description copied from interface:HasDependenciesReturns the known dependencies for this type. If this has dependencies whose values are not known statically, a dependency for theInjectorwill be included in the returned set.- Specified by:
getDependenciesin interfaceHasDependencies- Returns:
- a possibly empty set
-
toString
-