package gw.rating.flow.domain uses gw.util.Pair abstract class Statement { protected static final var OPEN_BRACE: String = "{" protected static final var CLOSE_BRACE: String = "}" protected var _parentStatement : Statement as Parent = null protected var _highlightElement : RateRoutineHighlightElement as HighlightElement protected var _start : Pair as readonly Start protected var _end : Pair as readonly End property get CodeSize():int { return 1 } construct() { } abstract function generate(context: GenerationContext) abstract function getOffendingOperand(issue: gw.lang.parser.IParseIssue) : CalcStepOperand //Interested sub-classes (e.g. IfStatement) override this function to return the offending sub-statement, others return "this" function getOffendingSubStatement(issue: gw.lang.parser.IParseIssue) : Statement { return this } function setStartAndEnd(start: Pair, end: Pair) { _start = start _end = end } }