T - the type of the keypublic final class TypedKey<T>
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
@NotNull io.leangen.geantyref.TypeToken<T> |
cls()
Gets the class of the key.
|
boolean |
equals(java.lang.Object o) |
int |
hashCode() |
@NotNull java.lang.String |
key()
Gets the key.
|
static <T> @NotNull TypedKey<T> |
of(@NotNull java.lang.Class<T> cls,
@NotNull java.lang.String key)
Creates a new typed key.
|
static <T> @NotNull TypedKey<T> |
of(@NotNull io.leangen.geantyref.TypeToken<T> type,
@NotNull java.lang.String key)
Creates a new typed key.
|
java.lang.String |
toString() |
@NotNull public static <T> @NotNull TypedKey<T> of(@NotNull @NotNull io.leangen.geantyref.TypeToken<T> type, @NotNull @NotNull java.lang.String key)
type - the type of the keykey - the key@NotNull public static <T> @NotNull TypedKey<T> of(@NotNull @NotNull java.lang.Class<T> cls, @NotNull @NotNull java.lang.String key)
cls - the class of the keykey - the key@NotNull public @NotNull io.leangen.geantyref.TypeToken<T> cls()
@NotNull public @NotNull java.lang.String key()
public int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Object