Uses of Class
org.faktorips.codegen.JavaCodeFragmentBuilder
Packages that use JavaCodeFragmentBuilder
-
Uses of JavaCodeFragmentBuilder in org.faktorips.codegen
Methods in org.faktorips.codegen that return JavaCodeFragmentBuilderModifier and TypeMethodDescriptionAdds an import entry to the code fragment under construction.Adds an import entry to the code fragment under construction.JavaCodeFragmentBuilder.annotation(Class<?> annotation, JavaCodeFragment params) Writes the annotation with the indicated parameters and a line separator. '@' character and a line feed will be automatically added.JavaCodeFragmentBuilder.annotation(String[] annotations) Writes the annotations.JavaCodeFragmentBuilder.annotation(String annotation, String paramName, String stringValue) Writes the annotation with the indicated parameter of type String. '@' character will be automatically added.JavaCodeFragmentBuilder.annotation(String annotation, JavaCodeFragment params) Writes the annotation with the indicated parameters. '@' character and a line feed will be automatically added.JavaCodeFragmentBuilder.annotationClassValueLn(String annotation, String paramName, String qualifiedClassName) Writes the annotation for a class value. '@' character and a line feed will be automatically added.JavaCodeFragmentBuilder.annotationLn(Class<?>... annotations) Writes each annotation with a line separator.JavaCodeFragmentBuilder.annotationLn(Class<?> annotation, String params) Writes the annotation with the indicated parameters and a line separator. '@' character and a line feed will be automatically added.JavaCodeFragmentBuilder.annotationLn(Class<?> annotation, String paramName, String stringValue) Writes the annotation with the indicated parameter of type String and adds a line separator. '@' character and a line feed will be automatically added.JavaCodeFragmentBuilder.annotationLn(Class<?> annotation, JavaCodeFragment params) Writes the annotation with the indicated parameters and a line separator. '@' character and a line feed will be automatically added.JavaCodeFragmentBuilder.annotationLn(String annotation) Writes the annotation.JavaCodeFragmentBuilder.annotationLn(String annotation, String params) JavaCodeFragmentBuilder.annotationLn(String annotation, String paramName, String stringValue) Writes the annotation with the indicated parameter of type String. '@' character and a line feed will be automatically added.JavaCodeFragmentBuilder.annotationLn(String annotation, JavaCodeFragment params) Writes the annotation with the indicated parameters. '@' character and a line feed will be automatically added.JavaCodeFragmentBuilder.append(char c) Appends the given char to the fragment's source code.JavaCodeFragmentBuilder.append(int i) Appends the given int to the fragment's source code.Appends the given String to the fragment's source code.JavaCodeFragmentBuilder.append(JavaCodeFragment fragment) Appends the given fragment to the fragment under construction and indents it properly.JavaCodeFragmentBuilder.appendClassName(Class<?> clazz) Appends the class' unqualified name to the source code and updates the import declaration (if necessary).JavaCodeFragmentBuilder.appendClassName(String qualifiedClassName) Appends the unqualified class name to the source code and updates the import declaration (if necessary).JavaCodeFragmentBuilder.appendGenerics(Class<?>... classes) Appends the generic parameters to the builder: <class1, class2, ...>.JavaCodeFragmentBuilder.appendGenerics(String... classNames) Appends the generic parameters to the builder: <className1, className2, ...>.JavaCodeFragmentBuilder.appendJavaModifier(int modifier) Append the Java modifier translated to a String, e.g. for java.lang.reflect.Modifier.PUBLIC "public" is appended.JavaCodeFragmentBuilder.appendJoin(List<JavaCodeFragment> parts, String separator) JavaCodeFragmentBuilder.appendln()Appends a line separator to fragment's source code.JavaCodeFragmentBuilder.appendln(char c) Appends the given char to the fragment's source code.Appends the given String and a line separator to the fragment's source code.JavaCodeFragmentBuilder.appendParameters(String[] parameters) JavaCodeFragmentBuilder.appendParameters(JavaCodeFragment[] parameters) JavaCodeFragmentBuilder.appendQuoted(String s) Encloses the given String with double quotes (") and appends it to fragment.JavaCodeFragmentBuilder.assignment(String variable, String value) Creates a new variable declaration.JavaCodeFragmentBuilder.assignment(String variable, JavaCodeFragment expression) Appends a new assignment.JavaCodeFragmentBuilder.classBegin(int modifier, String className) Appends the source code for the beginning of a new class at the end of the fragment under construction.JavaCodeFragmentBuilder.classBegin(int modifier, String className, Class<?> extendsClass, Class<?>[] interfaces) Appends the source code for the beginning of a new class at the end of the fragment under construction.JavaCodeFragmentBuilder.classBegin(int modifier, String className, String extendsClassName, String[] interfaces) Appends the source code for the beginning of a new class at the end of the fragment under construction.JavaCodeFragmentBuilder.classEnd()Writes the code at the end of a class.JavaCodeFragmentBuilder.closeBracket()Adds a closing bracket and decreases the indentation level by one afterwards.JavaCodeFragmentBuilder.constructorCall(String className, String[] parameters, boolean finishLine) append a constructor call: new <name>(parameters[0], parameters[1], ...)JavaCodeFragmentBuilder.constructorCall(String className, List<String> parameters, boolean finishLine) JavaCodeFragmentBuilder.enumBegin(int modifier, String className, String extendsClassName, String[] interfaces) Appends the source code for the beginning of a new enum at the end of the fragment under construction.JavaCodeFragmentBuilder.interfaceBegin(String interfaceName) Appends the source code for the beginning of a new interface at the end of the fragment under construction.JavaCodeFragmentBuilder.interfaceBegin(String interfaceName, String extendsInterfaceName) Appends the source code for the beginning of a new interface at the end of the fragment under construction.JavaCodeFragmentBuilder.interfaceBegin(String interfaceName, String[] extendedInterfaces) Appends the source code for the beginning of a new interface at the end of the fragment under construction.Puts the given text and annotations into a java doc comment.JavaCodeFragmentBuilder.method(int modifier, Class<?> returnType, String methodName, String[] argName, Class<?>[] argClass, Class<?>[] exceptionClasses, JavaCodeFragment body, String javadoc) Creates the Java source code for a method including signature, body and java doc.JavaCodeFragmentBuilder.method(int modifier, Class<?> returnType, String methodName, String[] argName, Class<?>[] argClass, JavaCodeFragment body, String javadoc) Creates the Java source code for a method including signature, body and java doc.JavaCodeFragmentBuilder.method(int modifier, Class<?> returnType, String methodName, String[] argName, Class<?>[] argClass, JavaCodeFragment body, String javadoc, String... javaDocAnnotations) Creates the Java source code for a method including signature, body and java doc.JavaCodeFragmentBuilder.method(int modifier, Class<?> returnType, String methodName, String[] argName, Class<?>[] argClass, JavaCodeFragment body, String javadoc, String[] javaDocAnnotations, String[] annotations) Creates the Java source code for a method including signature, body and java doc.JavaCodeFragmentBuilder.method(int modifier, String returnType, String methodName, String[] argName, String[] argClass, JavaCodeFragment body, String javadoc) Creates the Java source code for a method including signature, body and java doc.JavaCodeFragmentBuilder.method(int modifier, String returnType, String methodName, String[] argName, String[] argClass, JavaCodeFragment body, String javadoc, String... javaDocAnnotations) Creates the Java source code for a method including signature, body and java doc.JavaCodeFragmentBuilder.method(int modifier, String returnType, String methodName, String[] argName, String[] argClass, JavaCodeFragment body, String javadoc, String[] javaDocAnnotations, String[] annotations) Creates the Java source code for a method including signature, body and java doc.JavaCodeFragmentBuilder.methodBegin(int modifier, Class<?> returnType, String methodName, String[] argName, Class<?>[] argClass) Creates the Java source code for a method signature.JavaCodeFragmentBuilder.methodBegin(int modifier, Class<?> returnType, String methodName, String[] argName, Class<?>[] argClass, Class<?>[] exceptionClasses) Creates the Java source code for a method signature.JavaCodeFragmentBuilder.methodBegin(int modifier, Class<?> returnType, String methodName, String[] argName, Class<?>[] argClass, String javaDoc, String[] javaDocAnnotations) Creates the Java source code for a method signature.JavaCodeFragmentBuilder.methodBegin(int modifier, String returnType, String methodName, String[] argName, String[] argClass) Creates the Java source code for a method signature.JavaCodeFragmentBuilder.methodBegin(int modifier, String returnType, String methodName, String[] argName, String[] argClass, String javaDoc) Creates the Java source code for a method signature.JavaCodeFragmentBuilder.methodBegin(int modifier, String returnType, String methodName, String[] argName, String[] argClass, String[] exceptionClasses) Creates the Java source code for a method signature.JavaCodeFragmentBuilder.methodBegin(int modifier, String returnType, String methodName, String[] argName, String[] argClass, String javaDoc, String[] javaDocAnnotations) Creates the Java source code for a method signature.JavaCodeFragmentBuilder.methodCall(String name, String[] parameters, boolean finishLine) Writes a method call to the java code fragment builder.JavaCodeFragmentBuilder.methodCall(String name, List<String> parameters, boolean finishLine) JavaCodeFragmentBuilder.methodCall(String name, JavaCodeFragment[] parameterFragments, boolean finishLine) Writes a method call to the java code fragment builder.JavaCodeFragmentBuilder.methodEnd()Appends the source code for the the end of a method.JavaCodeFragmentBuilder.multiLineComment(String comment) JavaCodeFragmentBuilder.openBracket()Adds an opening bracket followed by a newline and increases the indentation level by one afterwards.JavaCodeFragmentBuilder.signature(int modifier, String returnType, String methodName, String[] argName, String[] argClass) Creates the Java source code for a method signature.JavaCodeFragmentBuilder.signature(int modifier, String returnType, String methodName, String[] argName, String[] argClass, boolean argFinal) Creates the Java source code for a method signature.JavaCodeFragmentBuilder.signature(int modifier, String returnType, String methodName, String[] argName, String[] argClass, String[] exceptionClasses) Creates the Java source code for a method signature.JavaCodeFragmentBuilder.signature(int modifier, String returnType, String methodName, String[] argName, String[] argClass, String javaDoc, String[] javaDocAnnotations) Creates the Java source code for a method signature.JavaCodeFragmentBuilder.signature(int modifier, JavaCodeFragment returnType, String methodName, String[] argName, String[] argClass) Creates the Java source code for a method signature.JavaCodeFragmentBuilder.signature(int modifier, JavaCodeFragment returnType, String methodName, String[] argName, String[] argClass, String[] exceptionClasses) Creates the Java source code for a method signature.JavaCodeFragmentBuilder.singleLineComment(String comment) JavaCodeFragmentBuilder.varDeclaration(int modifier, Class<?> clazz, String varName) Creates a new variable declaration.JavaCodeFragmentBuilder.varDeclaration(int modifier, Class<?> clazz, String varName, JavaCodeFragment expression) Creates a new variable declaration.JavaCodeFragmentBuilder.varDeclaration(int modifier, String className, String varName) Creates a new variable declaration.JavaCodeFragmentBuilder.varDeclaration(int modifier, String className, String varName, JavaCodeFragment expression) Creates a new variable declaration.JavaCodeFragmentBuilder.varDeclaration(int modifier, JavaCodeFragment className, String varName, JavaCodeFragment expression) Creates a new variable declaration.JavaCodeFragmentBuilder.varDefinition(Class<?> varClass, String varName, String varValue) Writes a variable definition.JavaCodeFragmentBuilder.varDefinition(String classOrTypeName, String variableName, String variableValue) Writes a variable definition.