()
| 70 | } |
| 71 | |
| 72 | static register() { |
| 73 | const typeRegistration = new TypeRegistration() |
| 74 | typeRegistration.typeName = ASSIGNMENT |
| 75 | typeRegistration.deserializer = Assignment.deserializer |
| 76 | typeRegistration.properties = [] |
| 77 | typeRegistration.childSets = { |
| 78 | left: NodeCategory.Expression, |
| 79 | right: NodeCategory.Expression, |
| 80 | } |
| 81 | typeRegistration.layout = new NodeLayout(HighlightColorCategory.VARIABLE_DECLARATION, [ |
| 82 | new LayoutComponent(LayoutComponentType.KEYWORD, 'set'), |
| 83 | new LayoutComponent(LayoutComponentType.CHILD_SET_TOKEN_LIST, 'left', ['variable']), |
| 84 | new LayoutComponent(LayoutComponentType.KEYWORD, '='), |
| 85 | new LayoutComponent(LayoutComponentType.CHILD_SET_ATTACH_RIGHT, 'right', ['value']), |
| 86 | ]) |
| 87 | typeRegistration.pasteAdapters[SPLOOT_EXPRESSION] = (node: SplootNode) => { |
| 88 | const exp = new SplootExpression(null) |
| 89 | exp.getTokenSet().addChild(node) |
| 90 | return exp |
| 91 | } |
| 92 | |
| 93 | registerType(typeRegistration) |
| 94 | registerNodeCateogry(ASSIGNMENT, NodeCategory.ExpressionToken) |
| 95 | registerAutocompleter(NodeCategory.ExpressionToken, new Generator()) |
| 96 | } |
| 97 | } |
nothing calls this directly
no test coverage detected