Package com.google.inject.throwingproviders
Extension for injecting objects that may throw at provision time; this extension requires
guice-throwingproviders.jar
.-
Interface Summary Interface Description CheckedProvider<T> Alternative to the GuiceProvider
that throws a checked Exception.CheckedProviderWithDependencies<T> A checked provider with dependencies, soHasDependencies
can be implemented when using theSecondaryBinder#using
methods.ThrowingProvider<T,E extends java.lang.Exception> Deprecated. useCheckedProvider
instead. -
Class Summary Class Description CheckedProviderMethod<T> A provider that invokes a method and returns its result.CheckedProviderMethodsModule Creates bindings to methods annotated with @CheckedProvides
.CheckedProviderMethodsModule.LogProvider A provider that returns a logger based on the method name.CheckedProviders Static utility methods for creating and working with instances ofCheckedProvider
.CheckedProviders.CheckedProviderInvocationHandler<T> CheckedProviders.ReturningHandler<T> CheckedProviders.ThrowingHandler CheckedProvideUtils Utilities for the throwing provider module.ProviderChecker Helper methods to verify the correctness of CheckedProvider interfaces.ProviderChecker.NotSyntheticOrBridgePredicate ThrowingProviderBinder Builds a binding for aCheckedProvider
.ThrowingProviderBinder.Result Represents the returned value from a call toCheckedProvider.get()
. -
Exception Summary Exception Description ThrowingProviderBinder.ResultException RuntimeException class to wrap exceptions from the checked provider. -
Annotation Types Summary Annotation Type Description CheckedProvides Annotates methods of aModule
to create aCheckedProvider
method binding that can throw exceptions.ThrowingInject A version of @Inject
designed for ThrowingProviders.