|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface MappedConfiguration<K,V>
Object passed into a service contributor method that allows the method provide contributed values to the service's configuration.
A service can collect contributions in three different ways:
| Method Summary | |
|---|---|
void |
add(K key,
V value)
Adds a keyed object to the service's contribution. |
void |
addInstance(K key,
Class<? extends V> clazz)
Adds a keyed object as an instantiated instance (with dependencies injected) of a class. |
void |
override(K key,
V value)
Overrides an existing contribution by its key. |
void |
overrideInstance(K key,
Class<? extends V> clazz)
Overrides an existing contribution with a new instance. |
| Method Detail |
|---|
void add(K key,
V value)
key - unique id for the valuevalue - to contribute
IllegalArgumentException - if key is not unique
void override(K key,
V value)
key - unique id of value to overridevalue - new value, or null to remove the key entirely
void addInstance(K key,
Class<? extends V> clazz)
key - unique id for the valueclazz - class to instantiate and contribute
void overrideInstance(K key,
Class<? extends V> clazz)
key - unique id of value to overrideclazz - class to instantiate as override
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||