Should we write detailed architecture design or just an outline when designing a program?
Posted
by
EpsilonVector
on Programmers
See other posts from Programmers
or by EpsilonVector
Published on 2011-11-21T07:52:10Z
Indexed on
2011/11/21
10:19 UTC
Read the original article
Hit count: 398
design
When I'm doing design for a task, I keep fighting this nagging feeling that aside from being a general outline it's going to be more or less ignored in the end. I'll give you an example:
I was writing a frontend for a device that has read/write operations. It made perfect sense in the class diagram to give it a read and a write function. Yet when it came down to actually writing them I realized they were literally the same function with just one line of code changed (read vs write function call), so to avoid code duplication I ended up implementing a do_io function with a parameter that distinguishes between operations. Goodbye original design.
This is not a terribly disruptive change, but it happens often and can happen in more critical parts of the program as well, so I can't help but wondering if there's a point to design more detail than a general outline, at least when it comes to the program's architecture (obviously when you are specifying an API you have to spell everything out).
This might be just the result of my inexperience in doing design, but on the other hand we have agile methodologies which sort of say "we give up on planning far ahead, everything is going to change in a few days anyway", which is often how I feel.
So, how exactly should I "use" design?
© Programmers or respective owner