Class CodeGenerationContext
java.lang.Object
com.atlassian.bamboo.specs.api.codegen.CodeGenerationContext
Context for generating Bamboo Specs code.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionDecrement code indentation.int
Current indentation level.importClassName
(Class clazz) Adds a class to the list of classes used in the generated code.Increment code indentation.newLine()
Produces a string with new line followed by a number of spaces determined according to the current indentation level.
-
Constructor Details
-
CodeGenerationContext
public CodeGenerationContext()
-
-
Method Details
-
incIndentation
Increment code indentation. -
decIndentation
Decrement code indentation. -
importClassName
Adds a class to the list of classes used in the generated code. The resulting list is used to generate import statements- Parameters:
clazz
- class object- Returns:
- class short name
-
newLine
Produces a string with new line followed by a number of spaces determined according to the current indentation level. -
getIndentationLevel
public int getIndentationLevel()Current indentation level.- Returns:
- current indentation level.
-
getImports
-