Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

To color ports by their type

...

  1. Create a Legend and a legend item Legend Item.Open the
  2. Right-click the Legend Item to open its Specification window of a legend Item.
     
  3. Click three dots Image Added next to the Adornment property to edit itClick the specification cell of the Adornment property, and then click Image Removed.
  4. In the Adornment Properties dialog, specify the desired adornment properties.
  5. Select the specification cell of the Elements by Condition property, and  click Image Removed.
  6. Click OK.
  7. Click three dots Image Added next to the Elements by Condition property to edit it. Elements by Condition dialog opens.
  8. Click Expert at Click Expert at the bottom of the dialog. The dialog is switched to the Expert mode.

  9. In the Structured Expression dialog on the left, click Create operation.
  10. Select the Metachain Navigation operation type.
  11. Click the Insert button to create the first step of the Metachain

  12. Select Create operation > Metachain Navigation.
  13. Click Insert.

  14. Select Port under Metaclass or Stereotype and under Property, select 

    Under Metaclass or Stereotype, select Port, and under Property, select 

    Type.
    Image Modified

  15. In the Structured Expression dialog on the left, click Create operation.
  16. Select the Operation from Model operation type.
  17. Select the Contains opaque behavior from the model.

  18. Select Create operation > Operation from Model > Contains.
  19. Drag-and-drop Metachain Navigation onto On the left side of the dialog, expand the Contains operation and drag-and-drop the previously created Metachain Navigation on the Input parameter.
  20. On the left side of the dialog, click the Obj parameter of the Contains operation.
  21. Select Element from the Values category.
  22. Click Image Removed and specify the Select Obj > Element > select the port type to verify.
  23. Click OK.

Sample projectColoring ports by their type.mdzip

...