eclipse-syson / syson

SysON: web-based graphical modelers for SysMLv2. Please visit https://mbse-syson.org and contact Obeo https://www.obeosoft.com/en/contact for more details!
https://mbse-syson.org
Eclipse Public License 2.0
99 stars 25 forks source link

[import] the cli.ide parser import some boolean field as string (and neither "true" nor "false"). #777

Open ebausson-obeo opened 6 days ago

ebausson-obeo commented 6 days ago

When parsing the .ast.json files, some field are badly interpreted because the expected boolean value is not in fact boolean.

The following field expect and are boolean: "isAlias": boolean, "isDefault": boolean, "isIndividual": boolean, "isInitial": boolean, "isNegated": boolean, "isParallel": boolean, "isReference": boolean, "isRecursive": boolean, "isVariation": boolean,

The following field expect boolean values, but are instead String:

ebausson-obeo commented 6 days ago

Exemple when importing from https://github.com/Systems-Modeling/SysML-v2-Release/blob/master/sysml/src/examples/Simple%20Tests as .ast.json:

ItemTest.sysml:222: "isReference": true, RequirementTest.sysml:143: "isRecursive": true, RequirementTest.sysml:1235: "isNegated": true, ViewTest.sysml:1138: "isAlias": true, StructuredControlTest.sysml:27: "isInitial": true, VariabilityTest.ast.json::417: "isVariation": true, OccurrenceTest.ast.json:326: "isIndividual": true, DefaultValueTest.ast.json:27: "isDefault": true, ImportTest.ast.json:108: "isRecursive": true, StateTest.ast.json:3435: "isParallel": true,

ItemTest.ast.json:325: "isAbstract": "abstract", AllocationTest.ast.json:659: "isEnd": "end", PartTest.ast.json:375: "isReadOnly": "readonly", PartTest.ast.json:450: "isDerived": "derived",