Package com.google.inject.internal
Class InternalProviderInstanceBindingImpl.CyclicFactory<T>
- java.lang.Object
-
- com.google.inject.internal.InternalProviderInstanceBindingImpl.Factory<T>
-
- com.google.inject.internal.InternalProviderInstanceBindingImpl.CyclicFactory<T>
-
- All Implemented Interfaces:
InternalFactory<T>,Provider<T>,HasDependencies,javax.inject.Provider<T>
- Direct Known Subclasses:
ProviderMethod
- Enclosing class:
- InternalProviderInstanceBindingImpl<T>
abstract static class InternalProviderInstanceBindingImpl.CyclicFactory<T> extends InternalProviderInstanceBindingImpl.Factory<T>
An base factory implementation that can be extended to provide a specialized implementation of aProviderWithExtensionVisitorand also implementsInternalFactory
-
-
Field Summary
-
Fields inherited from class com.google.inject.internal.InternalProviderInstanceBindingImpl.Factory
provisionCallback
-
-
Constructor Summary
Constructors Constructor Description CyclicFactory(InternalProviderInstanceBindingImpl.InitializationTiming initializationTiming)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Tget(InternalContext context, Dependency<?> dependency, boolean linked)Creates an object to be injected.private Tprovision(Dependency<?> dependency, InternalContext context, ConstructionContext<T> constructionContext)-
Methods inherited from class com.google.inject.internal.InternalProviderInstanceBindingImpl.Factory
doProvision, get, getSource, initialize
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.google.inject.spi.HasDependencies
getDependencies
-
-
-
-
Constructor Detail
-
CyclicFactory
CyclicFactory(InternalProviderInstanceBindingImpl.InitializationTiming initializationTiming)
-
-
Method Detail
-
get
public final T get(InternalContext context, Dependency<?> dependency, boolean linked) throws InternalProvisionException
Description copied from interface:InternalFactoryCreates an object to be injected.- Specified by:
getin interfaceInternalFactory<T>- Overrides:
getin classInternalProviderInstanceBindingImpl.Factory<T>- Parameters:
context- of this injectionlinked- true if getting as a result of a linked binding- Returns:
- instance that was created
- Throws:
InternalProvisionException- if a value cannot be provided
-
provision
private T provision(Dependency<?> dependency, InternalContext context, ConstructionContext<T> constructionContext) throws InternalProvisionException
- Throws:
InternalProvisionException
-
-