| Modifier and Type | Field and Description |
|---|---|
| private static final BindingScopingVisitor | |
| public static final Scope | NO_SCOPE
No scope; the same as not applying any scope at all. |
| public static final Scope |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| private static Injector | |
| public static boolean | isCircularProxy(Object object)
Returns true if the object is a proxy for a circular dependency, constructed by Guice because it encountered a circular dependency. |
| public static boolean | isScoped(Binding<?>
binding to check binding, final Scope scope implementation instance scope, final Class<? extends Annotation> scope annotation class scopeAnnotation)Returns true if |
| public static boolean |
| IS_SINGLETON_VISITOR | back to summary |
|---|---|
| private static final BindingScopingVisitor<Boolean> IS_SINGLETON_VISITOR | |
| NO_SCOPE | back to summary |
|---|---|
| public static final Scope NO_SCOPE No scope; the same as not applying any scope at all. Each time the Injector obtains an instance of an object with "no scope", it injects this instance then immediately forgets it. When the next request for the same binding arrives it will need to obtain the instance over again. This exists only in case a class has been annotated with a scope annotation such as
| |
| SINGLETON | back to summary |
|---|---|
| public static final Scope SINGLETON | |
| Scopes | back to summary |
|---|---|
| private Scopes() | |
| getInjector | back to summary |
|---|---|
| private static Injector getInjector(LinkedKeyBinding<?> linkedKeyBinding) | |
| isCircularProxy | back to summary |
|---|---|
| public static boolean isCircularProxy(Object object) Returns true if the object is a proxy for a circular dependency, constructed by Guice because it encountered a circular dependency. Scope implementations should be careful to not cache circular proxies, because the proxies are not intended for general purpose use. (They are designed just to fulfill the immediate injection, not all injections. Caching them can lead to IllegalArgumentExceptions or ClassCastExceptions.)
| |
| isScoped | back to summary |
|---|---|
| public static boolean isScoped(Binding<?> binding, final Scope scope, final Class<? extends Annotation> scopeAnnotation) Returns true if
| |
| isSingleton | back to summary |
|---|---|
| public static boolean isSingleton(Binding<?> binding) Returns true if
| |