public abstract class TypeWriter extends Modifiable implements HasClassReferences
| Modifier and Type | Class and Description |
|---|---|
static interface |
Writable.Context |
| Modifier and Type | Method and Description |
|---|---|
FieldWriter |
addField(Class<?> type,
String name) |
FieldWriter |
addField(TypeElement type,
String name) |
FieldWriter |
addField(TypeName type,
String name) |
void |
addImplementedType(TypeElement typeElement) |
void |
addImplementedType(TypeName typeReference) |
MethodWriter |
addMethod(Class<?> returnType,
String name) |
MethodWriter |
addMethod(TypeMirror returnType,
String name) |
MethodWriter |
addMethod(TypeName returnType,
String name) |
MethodWriter |
addMethod(TypeWriter returnType,
String name) |
ClassWriter |
addNestedClass(String name) |
ClassName |
name() |
Appendable |
write(Appendable appendable,
Writable.Context context) |
addModifiers, addModifiers, annotate, annotateclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitreferencedClassespublic ClassName name()
public MethodWriter addMethod(TypeWriter returnType, String name)
public MethodWriter addMethod(TypeMirror returnType, String name)
public MethodWriter addMethod(TypeName returnType, String name)
public MethodWriter addMethod(Class<?> returnType, String name)
public ClassWriter addNestedClass(String name)
public void addImplementedType(TypeName typeReference)
public void addImplementedType(TypeElement typeElement)
public FieldWriter addField(Class<?> type, String name)
public FieldWriter addField(TypeElement type, String name)
public FieldWriter addField(TypeName type, String name)
public Appendable write(Appendable appendable, Writable.Context context) throws IOException
IOExceptionCopyright © 2015 Google, Inc.. All Rights Reserved.