public class InterfaceGenerationHelper extends GenerationHelper
InterfaceGenerationHelper
is an internal class that provides common routines
only used by the annotation processors.Constructor and Description |
---|
InterfaceGenerationHelper(Writer sourceWriter) |
Modifier and Type | Method and Description |
---|---|
void |
generateEmptyMethodBody(String methodName,
String returnType)
Generates an empty method body.
|
void |
generateGetter(String fieldName,
String getterType) |
void |
generateGetter(VariableElement fieldElement) |
void |
generateInterfaceHeader(String inferfaceName,
Set<Modifier> modifiers,
String... extendedInterfaces) |
void |
generateSetter(String fieldName,
String fieldType) |
void |
generateSetter(VariableElement fieldElement) |
close, determineFinalConstantValue, determineWrapperClass, firstCharToUpperCase, generateAnnotation, generateConstantFieldDeclaration, generateFieldDeclaration, generateFieldDeclaration, generateFieldDeclarations, generateFieldList, generateFooter, generateImports, generateImports, generateModifierList, generatePackageDeclaration, implode, isConstant, isFinal, isPrimitive, isStatic, manufactureAccessorName, manufactureField, manufactureIndentation, manufactureSetterName, manufactureSetterName, print, print, println, println, println, printWithoutSpaces, replaceParameters, resetWhitespaces, setWhitespaces
public InterfaceGenerationHelper(Writer sourceWriter)
public void generateEmptyMethodBody(String methodName, String returnType)
writer.generateEmptyMethodBody("MyEntity", "stableId");
The following method body will be generated:
MyEntity stableId();
methodName
- returnType
- public void generateGetter(VariableElement fieldElement)
public void generateInterfaceHeader(String inferfaceName, Set<Modifier> modifiers, String... extendedInterfaces)
public void generateSetter(VariableElement fieldElement)
Copyright © 2010-2014 ArcBees. All Rights Reserved.