final class WildcardKey
extends java.lang.Object
Key for implementations that act as "wild-cards", meaning they match against any assignable type.
Since the wild-card type is Object and the associated qualifier may not be unique between implementations,
the qualifier is saved and replaced with a unique (per-implementation) pseudo-qualifier. The original qualifier is
available by casting the pseudo-qualifier to Provider and calling get().
| Modifier and Type | Class and Description |
|---|---|
private static interface |
WildcardKey.Qualified
Qualifier that captures a qualified implementation type. |
private static class |
WildcardKey.QualifiedImpl
Pseudo-
Annotation that can wrap any implementation type as a Qualifier. |
| Modifier and Type | Field and Description |
|---|---|
private static com.google.inject.TypeLiteral<java.lang.Object> |
OBJECT_TYPE_LITERAL |
| Modifier | Constructor and Description |
|---|---|
private |
WildcardKey() |
| Modifier and Type | Method and Description |
|---|---|
static com.google.inject.Key<java.lang.Object> |
get(java.lang.Class<?> type,
java.lang.annotation.Annotation qualifier) |