const classafEfan::EfanParser
sys::Obj afEfan::EfanParser
Parses efan template strings into Fantom code.
- fieldName
const Str fieldName := "_efan_output"
Name of the field that the generated template will be added to.
- make
new make(|This? f := null)
Standard it-block ctor. Use to set field values:
parser := EfanParser { it.srcCodePadding = 5 it.removeWhitespace = true it.fieldName = "_efan_output" }
- parse
ParseResult parse(Uri srcLocation, Str efanTemplate)
Parses the given
efan
template to Fantom code.- removeWhitespace
const Bool removeWhitespace := true
Controls whether
code
only lines are trimmed to remove (usually) unwanted line breaks.- srcCodePadding
const Int srcCodePadding := 5
When generating code snippets for parsing Errs, this is the number of src code lines the erroneous line will be padded with.