I like to document my signal slot connections (e.g. the connections in a special situation) with UML. I'm using the Enterprise Architect, and when having more than 5 Signals and/or Slots per class, it's getting very confusing. I tried the Flow Diagram and the Component Diagram:
Flow Diagrams: I modeled my classes as Processes and used the Ports for my signals/slots.
Component Diagrams: I used the Components for my classes and the Interfaces for my signal slots.
Do you have any experience with modeling signal/slots and what would you suggest? Are there any solutions which fit better for signal/slots?
Charly
I've always used the Sequence Diagram because I've found the 'lifelines' system of showing a transfer of flow between objects a natural fit to the signal/slots pattern. A quote from the wikipedia article linked to above:
Seems to agree with this viewpoint, and it's pretty easy to read.
As for the order in which slots are called, the Qt documentation clarifies this:
Timing is a relative term, and can be used to designate whatever you want it to: just so long as you're consistent and clear about what you're communicating, nobody will mind.