To get Incoming Associations of a Class


  1. Right-click a Class element and open the Specification window > Traceability > Create.
  2. Set the Name to 'Incoming associations'.
  3. Click Create operation > Filter.

    If you cannot see the Filter operation under Operations, make sure the Expert mode is enabled.

  4. Select Input > Metachain Navigation.
  5. Click Insert
  6. Under Metaclass or Stereotype, select Class, and under Property, select _associationOfEndType.
  7. Select Predicate > Operation from Model > Equals.
  8. Select A > Metachain Navigation
     
  9. Click Insert
  10. Under Metaclass or Stereotype, select Property, and under Property, select Type.
  11. Select Context > Reset.
  12. Select Context > Filter.
  13. Select Input > Simple Navigation. Select Member End and set Is Applied to true, and Direction to Source To Target

    If you cannot see the Member End property, make sure the 'Show relations criteria available only for context' check box is not selected.

  14. Select Predicate > Nested Operation
  15. Select Body > Simple Navigation. Select isNavigable() (Port) and set Is Applied to true, and Direction to Source To Target.
  16. Select B > Contextual Variable. Set the Value to THIS.
  17. Click OK.

Sample model

The model used in these examples is the Case Studies for Querying the Model sample model. To open this model, you need to download case studies for querying the model.mdzip