{ "csm": { "nodes": { "0": { "typename": { "type": "string", "value": "ButtonIcon" }, "position": { "type": "list", "value": [ 69, 122.1597 ] }, "orientation": { "type": "double", "value": 0 }, "scale": { "type": "list", "value": [ 1, 1 ] }, "mapper": { "type": "code", "value": "" }, "parser": { "type": "code", "value": "" }, "$contents": { "type": "map", "value": { "nodes": { "1": { "width": { "type": "double", "value": "120" }, "height": { "type": "double", "value": "50" }, "cornerRadius": { "type": "double", "value": "25" }, "style": { "type": "map", "value": { "stroke": "#af0000", "stroke-dasharray": "", "fill": "#000000", "fill-opacity": 0.05, "stroke-width": 2 } }, "mapper": { "type": "code", "value": "" }, "parser": { "type": "code", "value": "" }, "$type": "/Formalisms/__LanguageSyntax__/ConcreteSyntax/ConcreteSyntax/Rectangle", "position": { "type": "list", "value": [ 0, 0 ] }, "orientation": { "type": "double", "value": 0 }, "scale": { "type": "list", "value": [ 1, 1 ] } }, "2": { "textContent": { "type": "string", "value": "ExportModelToMD" }, "style": { "type": "map", "value": { "stroke": "#000000", "stroke-dasharray": "", "fill": "#ffffff", "fill-opacity": 0.75, "font-size": "13px", "stroke-width": 1 } }, "mapper": { "type": "code", "value": "({\"textContent\":getAttr(\"name\")})" }, "parser": { "type": "code", "value": "({\"name\":getAttr(\"textContent\")})" }, "$type": "/Formalisms/__LanguageSyntax__/ConcreteSyntax/ConcreteSyntax/Text", "position": { "type": "list", "value": [ 10, 13 ] }, "orientation": { "type": "double", "value": 0 }, "scale": { "type": "list", "value": [ 1, 1 ] } }, "3": { "$type": "/Formalisms/__LanguageSyntax__/ConcreteSyntax/ConcreteSyntax/Contain", "position": { "type": "list", "value": [ 17.74899850809561, 12.998998508095553 ] }, "orientation": { "type": "double", "value": 0 }, "scale": { "type": "list", "value": [ 1, 1 ] }, "link-style": { "type": "map", "value": { "stroke": "#00ffff", "stroke-dasharray": "", "stroke-opacity": 0.1, "arrow-start": "none", "arrow-end": "classic-wide-long" } } } }, "edges": [ { "src": "1", "dest": 3 }, { "src": 3, "dest": "2" } ] } }, "$asuri": { "type": "string", "value": "/Formalisms/__Utilities__/Buttons/Buttons/Button/0.instance" }, "$type": "/Formalisms/__Utilities__/Buttons/Buttons.defaultIcons/ButtonIcon" }, "1": { "typename": { "type": "string", "value": "ButtonIcon" }, "position": { "type": "list", "value": [ 211, 144.2083 ] }, "orientation": { "type": "double", "value": 0 }, "scale": { "type": "list", "value": [ 1, 1 ] }, "mapper": { "type": "code", "value": "" }, "parser": { "type": "code", "value": "" }, "$contents": { "type": "map", "value": { "nodes": { "1": { "width": { "type": "double", "value": "120" }, "height": { "type": "double", "value": "50" }, "cornerRadius": { "type": "double", "value": "25" }, "style": { "type": "map", "value": { "stroke": "#af0000", "stroke-dasharray": "", "fill": "#000000", "fill-opacity": 0.05, "stroke-width": 2 } }, "mapper": { "type": "code", "value": "" }, "parser": { "type": "code", "value": "" }, "$type": "/Formalisms/__LanguageSyntax__/ConcreteSyntax/ConcreteSyntax/Rectangle", "position": { "type": "list", "value": [ 0, 0 ] }, "orientation": { "type": "double", "value": 0 }, "scale": { "type": "list", "value": [ 1, 1 ] } }, "2": { "textContent": { "type": "string", "value": "ExportMetamodelToMD" }, "style": { "type": "map", "value": { "stroke": "#000000", "stroke-dasharray": "", "fill": "#ffffff", "fill-opacity": 0.75, "font-size": "13px", "stroke-width": 1 } }, "mapper": { "type": "code", "value": "({\"textContent\":getAttr(\"name\")})" }, "parser": { "type": "code", "value": "({\"name\":getAttr(\"textContent\")})" }, "$type": "/Formalisms/__LanguageSyntax__/ConcreteSyntax/ConcreteSyntax/Text", "position": { "type": "list", "value": [ 10, 13 ] }, "orientation": { "type": "double", "value": 0 }, "scale": { "type": "list", "value": [ 1, 1 ] } }, "3": { "$type": "/Formalisms/__LanguageSyntax__/ConcreteSyntax/ConcreteSyntax/Contain", "position": { "type": "list", "value": [ 17.74899850809561, 12.998998508095553 ] }, "orientation": { "type": "double", "value": 0 }, "scale": { "type": "list", "value": [ 1, 1 ] }, "link-style": { "type": "map", "value": { "stroke": "#00ffff", "stroke-dasharray": "", "stroke-opacity": 0.1, "arrow-start": "none", "arrow-end": "classic-wide-long" } } } }, "edges": [ { "src": "1", "dest": 3 }, { "src": 3, "dest": "2" } ] } }, "$asuri": { "type": "string", "value": "/Formalisms/__Utilities__/Buttons/Buttons/Button/1.instance" }, "$type": "/Formalisms/__Utilities__/Buttons/Buttons.defaultIcons/ButtonIcon" } }, "edges": [], "metamodels": [ "/Formalisms/__Utilities__/Buttons/Buttons.defaultIcons" ] }, "asm": { "nodes": { "0": { "name": { "type": "string", "value": "ExportModelToMD" }, "tooltip": { "type": "string", "value": "Exports a Model to metaDepth." }, "code": { "type": "code", "value": "_httpReq('GET', '/current.state?wid='+_context.wid, undefined, getFilename, true);\n\nfunction getFilename(statusCode, responseData) {\n\tresponseObj = JSON.parse(responseData);\n\tname = responseObj['data']['name'];\n\tparts = name.split('/');\n\tname = parts[parts.length - 1];\n\tname = name.split('.')[0];\n \n\t_openDialog(\n\t\t_CUSTOM,\n\t\t{'title':'Insert the name of the exported file.',\n\t\t 'widgets':[{'id':'file_name',\n\t\t\t\t\t 'type':'input',\n\t\t\t\t\t 'label':'Model name',\n\t\t\t\t\t 'default':name}]\n\t\t},\n\t\tfunction(data) {\n\t\t\t_httpReq('POST',\n\t\t\t\t\t '/plugins/exportmtomd/exportmtomd?wid='+_context.wid, \n\t\t\t\t\t {'name':data['file_name']});\n\t\t}\n\t);\n}" }, "$type": "/Formalisms/__Utilities__/Buttons/Buttons/Button" }, "1": { "name": { "type": "string", "value": "ExportMetamodelToMD" }, "tooltip": { "type": "string", "value": "Export a metamodel (SimpleClassDiagram) to metaDepth." }, "code": { "type": "code", "value": "_httpReq('GET', '/current.state?wid='+_context.wid, undefined, getFilename, true);\n\nfunction getFilename(statusCode, responseData) {\n\tresponseObj = JSON.parse(responseData);\n\tname = responseObj['data']['name'];\n\tparts = name.split('/');\n\tname = parts[parts.length - 1];\n\tname = name.split('.')[0];\n \n\t_openDialog(\n\t\t_CUSTOM,\n\t\t{'title':'Insert the name of your metamodel (for example \"RPGGame\")',\n\t\t 'widgets':[ {'id':'metamodel_name',\n\t\t\t\t\t 'type':'input',\n\t\t\t\t\t 'label':'Metamodel Name',\n\t\t\t\t\t 'default':name}]\n\t\t},\n\t\tfunction(data) {\n\t\t\t_httpReq('POST',\n\t\t\t\t\t '/plugins/exportmmtomd/exportmmtomd?wid='+_context.wid, \n\t\t\t\t\t {'name':data['metamodel_name']});\n\t\t}\n\t);\n}\n" }, "$type": "/Formalisms/__Utilities__/Buttons/Buttons/Button" } }, "edges": [], "metamodels": [ "/Formalisms/__Utilities__/Buttons/Buttons" ] } }