This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Merge all equal name-type elements.ajs | |
* Situation: Archi can make an element show up in different views. The relationships to and from that element in all these views are attached to the same element. | |
* Problem: If I accidentally make a copy of an element (e.g. by copying a view from one model to another), multiple elements may arise that have the same type and name. | |
* Such copies do not share relations, which violates an important benefit of Archi. | |
* Solution: This Archi-script ensures that all elements that share type and name are one and the same element. This will not affect any of your views. Executing this script is idempotent. | |
* Impact: after running this script | |
* - you will see that double occurrences in your elements list (in the "Models"-pane of Archi) are gone; | |
* - the information of all double occurrences has been accumulated in the remaining one without losing any information; | |
* - you will also see that the properties of the merged elements are all included in the re |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Show duplication.ajs | |
* Situation: Archi can make an element show up in different views. The relationships to and from that element in all these views are attached to the same element. | |
* Problem: If I accidentally make a copy of an element (e.g. by copying a view from one model to another), multiple elements may arise that have the same type and name. | |
* Such copies do not share relations, which violates an important benefit of Archi. | |
* Solution: This Archi-script signals the situation, so you can fix it if you want. | |
* (c) 2020 by Stef Joosten | |
*/ | |
var debug = true; | |
debug ? console.show():true; |