archimatetool / archi

Archi: ArchiMate Modelling Tool
https://www.archimatetool.com
MIT License
944 stars 269 forks source link

Specializations: allow specialisations to appear the palette #766

Closed ArchiRepo closed 1 year ago

ArchiRepo commented 2 years ago

It would be useful if the palette could include the specialisations in the model to make them easier to use in day to day modelling. This needn't make the palette too cluttered as it is already possible to create your own viewpoints in Archi. This would help modellers as well because it would help them to use the correct specialisations in a view. I once did this with a custom version of Archi (which was a lot of fuss) but helped the agile development teams because when they were modelling customer journeys they had a customer journey view that only gave them the concepts allowed in a customer journey in the palette. This meant it could be used by less experienced modeller but they still managed to keep within the metamodel. There are dangers in this but the benefits seemed to outweigh them. image

Phillipus commented 2 years ago

Adding to the GEF Palette dynamically presents a number of challenges:

jbsarrodie commented 2 years ago

I do agree that this kind of feature would be great. But knowing the challenges, I would prefer a way to let user create custom toolboxes that could contain single customized elements or even small patterns involving multiple concepts.

Phillipus commented 2 years ago

I do agree that this kind of feature would be great. But knowing the challenges...

I started to think about this recently..but the main issues are storing the meta info and the palette icon. It's possible to add things to the palette if we have (1) an icon, (2) a factory method for returning the new object, (3) some way to store this info either in the model or in another file.

Meanwhile, custom toolboxes are the way to go.

Phillipus commented 2 years ago

I can show Specializations in the palette.

Suppose we have already defined a Specialization, "Cat", specializing Business Actor. Now, if we want to create a new instance of this we have to:

  1. Drag and drop a Business Actor from the palette to a View
  2. Select the Business Actor in the Properties tab and select "Cat" from the Specializations drop-down

The changes in branch specialization-palette:

  1. If a model contains Specializations, entries are added to the palette using the Specialization's image if it has one, or the base class image if not
  2. Dragging the palette entry onto a View will create a new instance of that parent type, assign it to the given Specialization and use the name of the Specialization as the default name. The newly created View object will therefore inherit the image if it has one.
  3. The palette is dynamically updated if Specializations are modified in the Specializations Manager

palette

Phillipus commented 1 year ago

Archi 4.10