I'd like to write down the design of my program to understand the dependencies and calls better. I know there are class diagrams which show inheritance and attribute variables.

However I'd also like to document the input parameters to method functions and in particular which calls the methods function executes inside (e.g. on the input parameters).

Also sometimes it might be useful to show how actual objects are connected (if there is a standard structure).

This way I can have a better understanding of the modules and design before starting to program. Can you suggest a method to do this software design? It should be one-to-one to programming code structure so that I really notice all quirks beforehand (instead of high-level design where thing are hard to implement without further work). Maybe some special diagram or tool or a combination?

It is static dependency and call design rather than time dependent execution monitoring.

(I use Python if you have any specialized recommendations).

  • 1
    If you want something as concrete as code, write code.
    – user7043
    Jun 7, 2012 at 13:35
  • Questions about programming tools are usually considered more on-topic at stackoverflow: stackoverflow.com/questions (See the FAQ here: programmers.stackexchange.com/faq) You could search there to see if such a question has already been asked (and maybe even answered). You can also flag your own question to have the moderators migrate to StackOverflow if you think it would be better there. Jun 7, 2012 at 13:50
  • A google search for "Python call chart" yields this: pycallgraph.slowchop.com Is this what you are looking for? Jun 7, 2012 at 14:22
  • @delnan: It shouldn't be concrete code, but an overview that theoretically translates to code pieces. It's called software design.
    – Gere
    Jun 7, 2012 at 16:44
  • 1
    @Designer: Thanks for the suggestion! It's not so much about the tools, but rather the right method to approach this. For example the right diagrams as Ozair suggested. I'm new to UML and wasn't sure how to approach my particular design system. Pycallgraph helps to create such a graph but it is dynamic and graphs produces are a bit messy. So I wanted to design by hand :)
    – Gere
    Jun 7, 2012 at 16:46

2 Answers 2


I don't think there is any one diagram standard to represent everything.

Typically, I think for going from requirements to design, I would follow these steps:

  1. Use case diagrams
  2. Sequence diagrams
  3. Class Diagrams

You might also want to have a look at Collaboration diagrams.

The use cases give a higher level approach which you can skip in your case.

I have found the sequence diagrams most helpful in drawing out my mind. It helps put on paper the first logical objects and the interactions between them. I have also found these to be most helpful in understanding the behavior of an already built system.

Once those are clear and if you need then you can start making a class diagram with as much detail as you want. Class diagrams are static. If you are using a good IDE, you will hardly miss class diagrams.

  • Thanks a lot for the suggestion. That's the kind of approach I'm looking for. It wasn't clear to me what to use since "use case" seems too high-level, "sequence" too centered on a particular call flow rather than all possibilities more packed in one graph and "class" design isn't complex in my case. I though a mixture of "sequence" and "class". But I will just try your proposal :) I use Eclipse for Python.
    – Gere
    Jun 7, 2012 at 16:49
  • 1
    The OP may also want to look at collaboration diagrams (e.g.: agilemodeling.com/style/collaborationDiagram.htm. However, OP's requirement for analyzing input to each method is a bit out of the ordinary kind of requirement specially before design. In general a method gets just enough data to to do its work and that is that.
    – NoChance
    Jun 7, 2012 at 18:08
  • It's been one day and this is the first answer only. Actually Emmads suggestion is slightly better. Maybe there are even better answers. It doesn't sound nice if you demand it this way.
    – Gere
    Jun 9, 2012 at 7:51

However I'd also like to document the input parameters to method functions and in particular which calls the methods function executes inside (e.g. on the input parameters).

You're either solving the wrong problem or beginning at the wrong level of abstraction.

Consider the following quote:

"Bad programmers worry about the code. Good programmers worry about data structures and their relationships."

...And ask yourself, "Why do I need to worry about all of the methods and all of the input parameters in an application?"

Not the answer you're looking for? Browse other questions tagged or ask your own question.