Top Fields Constructors Methods
com.squareup.javapoet

public final Class ParameterizedTypeName

extends TypeName
Class Inheritance
Imports
java.io.IOException, java.lang.reflect.Modifier, .ParameterizedType, .Type, java.util.ArrayList, .Arrays, .LinkedHashMap, .List, .Map

Field Summary

Modifier and TypeField and Description
private final ParameterizedTypeName
public final ClassName
public final List<TypeName>
Inherited from com.squareup.javapoet.TypeName:
annotationsBOOLEANBYTECHARDOUBLEFLOATINTLONGOBJECTSHORTVOID

Constructor Summary

AccessConstructor and Description
pack-priv
ParameterizedTypeName(ParameterizedTypeName enclosingType, ClassName rawType, List<TypeName> typeArguments)

private
ParameterizedTypeName(ParameterizedTypeName enclosingType, ClassName rawType, List<TypeName> typeArguments, List<AnnotationSpec> annotations)

Method Summary

Modifier and TypeMethod and Description
public ParameterizedTypeName
pack-priv CodeWriter
public static ParameterizedTypeName
get(ClassName rawType, TypeName... typeArguments)

Returns a parameterized type, applying typeArguments to rawType.

public static ParameterizedTypeName
get(Class<?> rawType, Type... typeArguments)

Returns a parameterized type, applying typeArguments to rawType.

public static ParameterizedTypeName
get(ParameterizedType type)

Returns a parameterized type equivalent to type.

pack-priv static ParameterizedTypeName
get(ParameterizedType type, Map<Type, TypeVariableName> map)

Returns a parameterized type equivalent to type.

public ParameterizedTypeName
nestedClass(String name)

Returns a new ParameterizedTypeName instance for the specified name as nested inside this class.

public 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.

public TypeName
Inherited from com.squareup.javapoet.TypeName:
annotatedarrayComponentasArrayboxconcatAnnotationsemitAnnotationsequalsgetgetgetgethashCodeisAnnotatedisBoxedPrimitiveisPrimitivelistlisttoStringunbox

Field Detail

enclosingTypeback to summary
private final ParameterizedTypeName enclosingType
rawTypeback to summary
public final ClassName rawType
typeArgumentsback to summary
public final List<TypeName> typeArguments

Constructor Detail

ParameterizedTypeNameback to summary
pack-priv ParameterizedTypeName(ParameterizedTypeName enclosingType, ClassName rawType, List<TypeName> typeArguments)
ParameterizedTypeNameback to summary
private ParameterizedTypeName(ParameterizedTypeName enclosingType, ClassName rawType, List<TypeName> typeArguments, List<AnnotationSpec> annotations)

Method Detail

annotatedback to summary
public ParameterizedTypeName annotated(List<AnnotationSpec> annotations)

Overrides com.squareup.javapoet.TypeName.annotated.

Annotations
@Override
emitback to summary
pack-priv CodeWriter emit(CodeWriter out) throws IOException

Overrides com.squareup.javapoet.TypeName.emit.

Annotations
@Override
getback to summary
public static ParameterizedTypeName get(ClassName rawType, TypeName... typeArguments)

Returns a parameterized type, applying typeArguments to rawType.

getback to summary
public static ParameterizedTypeName get(Class<?> rawType, Type... typeArguments)

Returns a parameterized type, applying typeArguments to rawType.

getback to summary
public static ParameterizedTypeName get(ParameterizedType type)

Returns a parameterized type equivalent to type.

getback to summary
pack-priv static ParameterizedTypeName get(ParameterizedType type, Map<Type, TypeVariableName> map)

Returns a parameterized type equivalent to type.

nestedClassback to summary
public ParameterizedTypeName nestedClass(String name)

Returns a new ParameterizedTypeName instance for the specified name as nested inside this class.

nestedClassback to summary
public 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.

withoutAnnotationsback to summary
public TypeName withoutAnnotations()

Overrides com.squareup.javapoet.TypeName.withoutAnnotations.

Annotations
@Override