By ordering methods roughly in the sequence they are called, it can improve comprehension and maintainability.  Most experienced developers will do this instinctively.

For example the order of methods to process images might be as follows:

  1. Constructors

  2. init()

  3. mainLoop()

  4. getNextImage()

  5. validateImage()

  6. createOutputFolder()

  7. processImage()

  8. notifyListeners()

blog comments powered by Disqus