How to remove relation in software?????????????

UML related questions and discussions

Moderator: Moderators

How to remove relation in software?????????????

Postby Ian.Wilson@gd-ms.com » Tue Jul 16, 2019 12:27 pm

I've been writing code in JavaScript Rhino to read/write Allocations relations inside of a Allocation Matrix Diagram. So far i've been able to read and write Allocations into the Allocation Matrix. I've been using the "Automaton Macro API" Class to create relationships between elements. However, there does not seem to be a way to delete relationships once they've been created. Is there a command to delete relationships?
Ian.Wilson@gd-ms.com
Forum Newbie
Forum Newbie
 
Posts: 4
Posts Rating:1
Joined: Tue Jul 16, 2019 12:04 pm

Re: How to remove relation in software?????????????

Postby Ian.Wilson@gd-ms.com » Tue Jul 23, 2019 11:30 am

SOLVED:

You can remove any element in the model with the following commands (This is written with JavaScript Rhino):

var a = AutomatonMacroAPI.getOpaqueObjectByPath("Object_Path"); //Select an Element with the given path in the containment tree.

AutomatonMacroAPI.removeElement(a); //Remove Element "a"
Ian.Wilson@gd-ms.com
Forum Newbie
Forum Newbie
 
Posts: 4
Posts Rating:1
Joined: Tue Jul 16, 2019 12:04 pm


Return to Software Modeling (UML)

Who is online

Users browsing this forum: No registered users and 0 guests