Jump to Menu

How to Convert a Model Element to Another Type?

Despite visual modeling may vary in approach and scope, there is a basic principle shared in common. That is, rather than a one-off action, visual modeling is a continuous activity. As your project develops, requirements will be set, issues will be found, old requirements may no longer be valid, etc. Inevitably, all these lead to changes in your existing design. When re-drawing could mean a bigger time investment, you would most likely refine your existing diagrams instead. In such case, the ability to convert a model element in the diagram from one type to another will be very useful.

Compatible edition(s): Enterprise, Professional, Standard, Modeler

  • March 14, 2012
  • Views: 30,202
  • PDF

When do You Convert a Model Element Type?

UML supports a rich set of notation. You can always find the best notation for thorough expression. When the type of an element is no longer appropriate or is not the best type to express an idea, you will want to replace it with a better notation. Here are some of the situations when type conversion is needed.

Design Evolvement

Take BPMN as an example. Task and sub-process are two notations introduced by BPMN. They both model activities to do within a business process. If you need to model an order processing system with BPMN, you may initially use a BPMN task to model the Ship Order activity. As the design evolves, let's just say that shipping order turns out to be much more complex than you thought and involves several sub-activities like arranging shipment, delivering goods, collecting payment, etc. To depict that, you need to convert the atomic task to a sub-process, not only for representing its complex nature but also for making it possible to drill down the process and model its details.


design evolement

Correcting Mistakes

Things are never perfect and so are our work. Sometimes your knowledge in modeling language falls short. You may mistakenly apply a wrong type of model element in your design. For example, you could have incorrectly treated UML activity as UML action. When you realize it is a mistake, you want to correct it.


correct mistake

Describe More Precisely What You Want to Express

Some notations are sub-types of a more general one. For example, send-signal-action is a kind of UML action that creates a signal from its input and transmits it to the next object. While using UML action in a broad manner is not exactly wrong, using send-signal-action would reflect the truth more precisely.


convert action

Convert Action to Send-Signal-Action

In this tutorial, we will try to convert several general UML actions in an activity to send signal actions. Take a look at the diagram below. An order is created initially. Then, a shipment request is sent to the warehouse. After that, an invoice is created and sent to the customer. As signals are sent by the Fill Order Request and Notify Customer actions, we will convert them to send-signal-action.

Create a UML activity diagram. Draw the diagram below and get ready for the tutorial.


original activity diagram
  1. Select Window > Application Options... from the application toolbar.
  2. The convert-type function is an advanced feature that can only be accessed when running in Advanced UI mode. Select General from the list on the left hand side.
  3. Under the Environment page, check Advanced UI mode.
  4. Click OK.
  5. Save your project and restart Visual Paradigm.
  6. Right-click on the Fill Order Request action and select Related Elements > Change Type... from the popup menu.
  7. In the Change Model Element Type dialog box, enter Send Signal Action for the type to convert to.
    sel send signal action
  8. Click Next.
  9. Due to the difference in the element type, some properties, relationships and tagged values may no longer be compatible after the conversion and are forced to be discarded. In the Change Model Element Type window, you will find the properties, relationships and tagged values that will be kept and discarded after the conversion. The data that will be discarded is put on the left hand side while the resolvable data is on the right.
  10. Click OK at bottom right. Note that the undo history will be cleared after the conversion, meaning that you cannot perform any undo action after it. This is the updated diagram:
    updated activity diagram
  11. Convert Notify Customer from UML action to send-signal-action. Finally, the diagram should look like this:
    final diagram


Turn every software project into a successful one.

We use cookies to offer you a better experience. By visiting our website, you agree to the use of cookies as described in our Cookie Policy.

OK