|
@@ -25,7 +25,6 @@ String function cmd_help_m(write : Boolean):
|
|
|
result = result + " attr_add_code -- Add a coded attribute to an element\n"
|
|
|
result = result + " attr_del -- Delete an attribute of an element\n"
|
|
|
result = result + " attr_modify -- Modify an attribute of an element\n"
|
|
|
- result = result + " retype -- Change the type of an element\n"
|
|
|
result = result + " upload -- Upload a completely new model\n"
|
|
|
else:
|
|
|
result = result + " == READ-ONLY ==\n"
|
|
@@ -420,19 +419,6 @@ String function cmd_types(model : Element):
|
|
|
|
|
|
return result!
|
|
|
|
|
|
-String function cmd_retype(write : Boolean, model : Element, element_name : String, new_type : String):
|
|
|
- if (write):
|
|
|
- if (dict_in(model["model"], element_name)):
|
|
|
- if (dict_in(model["metamodel"]["model"], new_type)):
|
|
|
- retype(model, element_name, new_type)
|
|
|
- return "Success"!
|
|
|
- else:
|
|
|
- return "Element not found: " + new_type!
|
|
|
- else:
|
|
|
- return "Element not found: " + element_name!
|
|
|
- else:
|
|
|
- return "Write permission denied"!
|
|
|
-
|
|
|
String function cmd_read_association_source(write : Boolean, model : Element, element_name : String):
|
|
|
if (dict_in(model["model"], element_name)):
|
|
|
if (is_edge(model["model"][element_name])):
|
|
@@ -509,8 +495,6 @@ Boolean function modify(model : Element, write : Boolean):
|
|
|
output(cmd_read_defined_attrs(model, single_input("Name?")))
|
|
|
elif (cmd == "types"):
|
|
|
output(cmd_types(model))
|
|
|
- elif (cmd == "retype"):
|
|
|
- output(cmd_retype(write, model, single_input("Name?"), single_input("New type?")))
|
|
|
elif (cmd == "read_association_source"):
|
|
|
output(cmd_read_association_source(write, model, single_input("Name?")))
|
|
|
elif (cmd == "read_association_destination"):
|