MCPcopy Create free account
hub / github.com/SplootCode/splootcode / constructor

Method constructor

packages/language-web/types/js/if.ts:41–47  ·  view source on GitHub ↗
(parentReference: ParentReference)

Source from the content-addressed store, hash-verified

39
40export class IfStatement extends SplootNode {
41 constructor(parentReference: ParentReference) {
42 super(parentReference, IF_STATEMENT)
43 this.addChildSet('condition', ChildSetType.Single, NodeCategory.Expression)
44 this.getChildSet('condition').addChild(new SplootExpression(null))
45 this.addChildSet('trueblock', ChildSetType.Many, NodeCategory.Statement)
46 // this.addChildSet('elseblock', ChildSetType.Many, NodeCategory.Statement);
47 }
48
49 getCondition() {
50 return this.getChildSet('condition')

Callers

nothing calls this directly

Calls 3

addChildSetMethod · 0.80
addChildMethod · 0.80
getChildSetMethod · 0.45

Tested by

no test coverage detected