public class ApplicationAspectMap extends Object
application aspects
in a type safe manner.Constructor and Description |
---|
ApplicationAspectMap() |
Modifier and Type | Method and Description |
---|---|
<A> A |
get(ApplicationAspectType<A> type)
Get the correctly typed aspect for a type.
|
<A,C extends A> |
put(ApplicationAspectType<A> type,
C aspect)
Put an aspect for specific type.
|
void |
remove(ApplicationAspectType<?> type)
Remove the aspect for the given type from this map.
|
public <A,C extends A> void put(@NotNull ApplicationAspectType<A> type, @NotNull C aspect)
String aspect = ...;
AspectType<CharSequence> type = ...;
put(type, aspect);
A
- The type of the aspect.C
- The concrete implementation type of the aspect.type
- The aspect type.aspect
- The aspect implementation.public void remove(ApplicationAspectType<?> type)
type
- The aspect type.@Nullable public <A> A get(ApplicationAspectType<A> type)
AspectType<CharSequence> type = ...;
CharSequence aspect = get(type);
A
- The type of the aspect.type
- The aspect type to look up.Copyright © 2021 e-Spirit AG. All Rights Reserved. Build 5.2.210210