se.jbee.inject.util
Class Scoped
Object
se.jbee.inject.util.Scoped
public class Scoped
- extends Object
Utility as a factory to create/use Scopes.
- Author:
- Jan Bernitt (jan@jbee.se)
| Methods inherited from class Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DEPENDENCY_TYPE_KEY
public static final Scoped.KeyDeduction DEPENDENCY_TYPE_KEY
DEPENDENCY_INSTANCE_KEY
public static final Scoped.KeyDeduction DEPENDENCY_INSTANCE_KEY
TARGET_INSTANCE_KEY
public static final Scoped.KeyDeduction TARGET_INSTANCE_KEY
TARGETED_DEPENDENCY_TYPE_KEY
public static final Scoped.KeyDeduction TARGETED_DEPENDENCY_TYPE_KEY
INJECTION
public static final Scope INJECTION
- Often called the 'default' or 'prototype'-scope. Asks the
Injectable once per
injection.
APPLICATION
public static final Scope APPLICATION
- Asks the
Injectable once per binding. Thereby instances become singletons local to
the application.
THREAD
public static final Scope THREAD
- Asks the
Injectable once per thread per binding which is understand commonly as a
usual 'per-thread' singleton.
DEPENDENCY_TYPE
public static final Scope DEPENDENCY_TYPE
DEPENDENCY_INSTANCE
public static final Scope DEPENDENCY_INSTANCE
TARGET_INSTANCE
public static final Scope TARGET_INSTANCE
DEPENDENCY
public static final Scope DEPENDENCY
Scoped
public Scoped()
uniqueBy
public static Scope uniqueBy(Scoped.KeyDeduction keyDeduction)
asSnapshot
public static Repository asSnapshot(Repository src,
Repository dest)