public class Singleton extends ObjectProvider
| Modifier and Type | Field and Description |
|---|---|
protected ObjectMethod |
destroy |
protected Object |
instance |
ctx, id, type| Constructor and Description |
|---|
Singleton(InjectionContext ctx,
Class<?> type,
Object instance,
String id,
ObjectMethod destroy)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
Object |
provide()
Provide an object for injection.
|
getId, getTypeprotected Object instance
protected ObjectMethod destroy
public Singleton(InjectionContext ctx, Class<?> type, Object instance, String id, ObjectMethod destroy)
public Object provide()
ObjectProviderprovide in class ObjectProviderpublic void close()
close in interface Closeableclose in interface AutoCloseableclose in class ObjectProviderCopyright © 2018. All rights reserved.