const classafFancordion::CommandCtx
sys::Obj afFancordion::CommandCtx
Contains contextual information about a Fancordion command.
- applyVariables
Str applyVariables(Str text := this.cmdPath)
Applies Fancordion variables to the given str. Specifically it replaces portions of the string with:
#TEXT -> cmdText.toCode
#COLS -> tableCols.toCode
#COL[0] -> tableCols[0].toCode
#COL[1] -> tableCols[1].toCode
#COL[n] -> tableCols[n].toCode
#FIXTURE -> "fixture"
- cmdPath
const Str cmdPath
The path portion of the command URI (minus the scheme):
[text]`scheme:path`
- cmdScheme
const Str cmdScheme
The scheme portion of the command URI:
[text]`scheme:path`
- cmdText
const Str cmdText
The text portion of the command:
[text]`scheme:path`
For table column commands this is the column text.
- cmdUri
const Str cmdUri
The command URI.
- executeOnFixture
Void executeOnFixture(Obj fixture, Str code)
Executes the given code against the fixture instance. Example:
executeOnFixture(fixture, "echo()") --> fixture.echo()
- getFromFixture
Obj? getFromFixture(Obj fixture, Str code)
Executes the given code on the fixture instance and returns a value. Example:
getFromFixture(fixture, "toStr()") --> return fixture.toStr()
- ignore
const Bool ignore
Is set to
true
if there has been previous errors in the fixture and this command should be ignored.- tableCols
const Str[]? tableCols
The columns that make up a table row. Only available in table row commands.