YS

Hello all!

I try to consolidate the equal (copies) objects by script, and I use method "ObjDefObjectMaster.Consolidate (ObjDef[] SlaveObjcts, true)".

After that, the objects consolidated, their copies vanished from group, but did not vanished from model.

Tell me please, how can I consolidate the objects to vanished their copies from group and model.

by Yuriy Stolyarov Author
Posted on Wed, 10/09/2019 - 08:49

I hope, that ARIS has some method, that does what I describe in my previous message.

But now I simply try to remove ObjOccs the objects from the model. And it works.

for (var i = 0; i < masOcc.length; i++) {

        masOcc[i].Remove();

    }

0
by Kay Fischbach
Posted on Wed, 10/09/2019 - 09:34

May I ask why you would want to remove occurrences from models?

Don't the occurrences belong into those models?

The entire point of consolidation, is to allow your ObjDefMaster to take over any occurrences of your slave objects.

It's meant to be used in cases like the following:

You have a widely used IT system, which is used in many models. Then you get a new modeler, who doesn't know this IT system exists, so he/she creates a new IT system and uses this IT system in their models.

Now, to consolidate the data basis (aka the object definition) you can use the ARIS "consolidate" functionality, which allows your widely used IT system to take over all of the occurrences of the falsely created new IT system. The new modeler wanted to see that IT system in their models after all. All you want however is that changes to this IT system are reflected database wide (e. g. to pass around the information that the system will be down for maintenance, or that it will be deprecated soon).

It doesn't make any sense to use consolidate in combination with deletion, because consolidation already removes the falsely created object definition and there shouldn't be anything else to delete. Occurrences of the falsely created object definition rightfully become occurrences of the master definition, therefore you shouldn't delete them.

Maybe your use-case is not actually consolidation? Could you describe your initial situation and what you're trying to achieve? Maybe there is another way to realize what you want to achieve.

0
by Yuriy Stolyarov Author
Posted on Wed, 10/09/2019 - 12:41

In reply to by Kay Fischbach

There is a group "Directories", in the subfolders of which there are environment objects of functions (registry of environment objects).

When a model variant is created, these objects in it are created as copy-instances (links).

All other objects (functions, events, rules) are created in the version as copy-definitions.

In the process of creating variants and completing models, users sometimes do not follow the rules.

They create environment objects in folders with models, instead of using these objects from the Catalogs group. 

When adjusting the model, these objects are transferred from folders with models in subfolders of the "Directories" folder.

Because of this, we get the same objects, to eliminate which the "Consolidation" method is used. There weren’t many such objects before, the consolidation process was performed manually. Now there are much more objects a software solution to this problem was required.

0
by Kay Fischbach
Posted on Wed, 10/09/2019 - 15:39

In reply to by Felix101

Ok, but which step of this process requires you to delete occurrences/why do you want to remove occurrences anywhere?

Users clearly want to use the environment(s) in question in their models. That's why they created occurrences of environment(s) (all be it maybe ones with the wrong object definition) in their model.

If you were to perform consolidation the right way, the following would happen:

  1. The report takes the occurrences of the wrong object definition and performs the ".ReplaceObjDef(...)" method on them to re-map the occurrence to the correct object definition found in "Directories"

    (it's worth looking that method up in the ARIS Script help, it can be found in the ObjOcc Report class).

    After this the models should be fine - the used environments are associated with the object definition found within "Directories".
  2. The report deletes the leftover wrong object definition, which can't possibly have any more occurrences, because all the occurrences of the wrong object definition were taken over by the "Directories" object definition.

Those two steps are the essential steps that were compressed into a single "Consolidate(...)" method. There is a bit more to it (e. g. the report will also try to merge the attribute values of the object definitions in question), but the two steps above are the essential things "Consolidate(...)" performs.

 

Edit: Maybe one more thing to look out for: by default "Consolidate(slaveObjDefs, true)" will try to merge attribute values, which may lead to undesirable results in case you are ordered to maintain the status-quo of the "Directories" objects at all costs. If you want to disable attribute merging, "Consolidate(slaveObjDefs, true, false)" is the thing to use.

0

Featured achievement

Rookie
Say hello to the ARIS Community! Personalize your community experience by following forums or tags, liking a post or uploading a profile picture.
Recent Unlocks

Leaderboard

|
icon-arrow-down icon-arrow-cerulean-left icon-arrow-cerulean-right icon-arrow-down icon-arrow-left icon-arrow-right icon-arrow icon-back icon-close icon-comments icon-correct-answer icon-tick icon-download icon-facebook icon-flag icon-google-plus icon-hamburger icon-in icon-info icon-instagram icon-login-true icon-login icon-mail-notification icon-mail icon-mortarboard icon-newsletter icon-notification icon-pinterest icon-plus icon-rss icon-search icon-share icon-shield icon-snapchat icon-star icon-tutorials icon-twitter icon-universities icon-videos icon-views icon-whatsapp icon-xing icon-youtube icon-jobs icon-heart icon-heart2 aris-express bpm-glossary help-intro help-design Process_Mining_Icon help-publishing help-administration help-dashboarding help-archive help-risk icon-knowledge icon-question icon-events icon-message icon-more icon-pencil forum-icon icon-lock