public interface Freeform extends Expression
Expression
subinterface for freeform expressions. The freeform
expression is a very general container expression for (hopefully) exceptional
instances in which it the api is too difficult or cumbersome and one needs to
inject a source code directly. This structure simply copies the text given in
setCode. No semicolon is appended.Modifier and Type | Method and Description |
---|---|
Freeform |
dedentLine()
Decrements the tab and calls newLine()
|
String |
getCode()
Gets the code for this expression.
|
int |
getIndentNumber()
Returns the current number of indentation levels.
|
Freeform |
indentLine()
Increments the tab and calls newLine()
|
boolean |
isLineNew()
Returns true if no characters have been written since the last call of
newLine().
|
Freeform |
newLine()
Adds a the newLine string according to
System.getProperty("line.separator") and the line is padded
with the n tab characters where n is the number returned by
getIndentNumber() . |
Freeform |
resetLine()
Resets the tab counter to zero and calls the newLine() method.
|
Freeform |
setCode(String code)
Sets the code for this expression.
|
Freeform |
space()
Writes a single space.
|
Freeform |
write(boolean b)
Writes a boolean.
|
Freeform |
write(char c)
Writes a single character.
|
Freeform |
write(char[] chars)
Writes an array of characters.
|
Freeform |
write(double d)
Writes a double.
|
Freeform |
write(float f)
Writes a float.
|
Freeform |
write(int i)
Writes an integer.
|
Freeform |
write(Object o)
Writes an object.
|
Freeform |
write(Object[] ao)
Writes each element of the given object array.
|
Freeform |
write(String s)
Writes a string.
|
getType
applyStyle, cast, getComment, isActive, isBlockWithAbruptCompletion, setComment, toCode, visit, vm
Freeform dedentLine()
String getCode()
int getIndentNumber()
Freeform indentLine()
boolean isLineNew()
Freeform newLine()
System.getProperty("line.separator")
and the line is padded
with the n tab characters where n is the number returned by
getIndentNumber()
.Freeform resetLine()
Freeform space()
Freeform write(boolean b)
Freeform write(char c)
Freeform write(char[] chars)
Freeform write(double d)
Freeform write(float f)
Freeform write(int i)
Copyright © 2000–2018 jenesis4java. All rights reserved.