MCPcopy
hub / github.com/google/guava / of

Method of

guava/src/com/google/common/reflect/TypeToken.java:169–171  ·  view source on GitHub ↗

Returns an instance of type token that wraps {@code type}.

(Class<T> type)

Source from the content-addressed store, hash-verified

167
168 /** Returns an instance of type token that wraps {@code type}. */
169 public static <T> TypeToken<T> of(Class<T> type) {
170 return new SimpleTypeToken<>(type);
171 }
172
173 /** Returns an instance of type token that wraps {@code type}. */
174 public static TypeToken<?> of(Type type) {

Callers 15

getInstanceMethod · 0.95
putInstanceMethod · 0.95
whereMethod · 0.95
resolveTypeMethod · 0.95
resolveSupertypeMethod · 0.95
boundAsSuperclassMethod · 0.95
boundsAsInterfacesMethod · 0.95
getSubtypeMethod · 0.95
isSupertypeOfMethod · 0.95
isSubtypeOfMethod · 0.95
wrapMethod · 0.95
unwrapMethod · 0.95

Calls

no outgoing calls

Tested by 15

getDefaultValueMethod · 0.76
testPutThrowsMethod · 0.76
testPutAllThrowsMethod · 0.76
testPutAndGetInstanceMethod · 0.76
testNullMethod · 0.76
samplesMethod · 0.76