public final class ParameterizedTypeName extends TypeName
| Modifier and Type | Field and Description |
|---|---|
ClassName |
rawType |
List<TypeName> |
typeArguments |
| Modifier and Type | Method and Description |
|---|---|
ParameterizedTypeName |
annotated(List<AnnotationSpec> annotations) |
static ParameterizedTypeName |
get(Class<?> rawType,
Type... typeArguments)
Returns a parameterized type, applying
typeArguments to rawType. |
static ParameterizedTypeName |
get(ClassName rawType,
TypeName... typeArguments)
Returns a parameterized type, applying
typeArguments to rawType. |
static ParameterizedTypeName |
get(ParameterizedType type)
Returns a parameterized type equivalent to
type. |
ParameterizedTypeName |
nestedClass(String name)
Returns a new
ParameterizedTypeName instance for the specified name as nested
inside this class. |
ParameterizedTypeName |
nestedClass(String name,
List<TypeName> typeArguments)
Returns a new
ParameterizedTypeName instance for the specified name as nested
inside this class, with the specified typeArguments. |
TypeName |
withoutAnnotations() |
annotated, box, concatAnnotations, equals, get, get, hashCode, isAnnotated, isBoxedPrimitive, isPrimitive, toString, unboxpublic final ClassName rawType
public ParameterizedTypeName annotated(List<AnnotationSpec> annotations)
public TypeName withoutAnnotations()
withoutAnnotations in class TypeNamepublic ParameterizedTypeName nestedClass(String name)
ParameterizedTypeName instance for the specified name as nested
inside this class.public ParameterizedTypeName nestedClass(String name, List<TypeName> typeArguments)
ParameterizedTypeName instance for the specified name as nested
inside this class, with the specified typeArguments.public static ParameterizedTypeName get(ClassName rawType, TypeName... typeArguments)
typeArguments to rawType.public static ParameterizedTypeName get(Class<?> rawType, Type... typeArguments)
typeArguments to rawType.public static ParameterizedTypeName get(ParameterizedType type)
type.Copyright © 2016 Square, Inc.. All Rights Reserved.