Object-Oriented Analysis and Design

The steps to take before programming anything are analysis and design. Analysis is the process of understanding and detailing the problem you are trying to solve. Design is the actual planning of your solution.

With trivial problems (e.g., computing the Fibonacci series[6]), you may not need an extensive analysis period, but with complex business problems, the analysis process can take weeks or even months. One powerful analysis technique is to create what are called use-case scenarios, in which you describe in some detail how the system will be used. Among the other considerations in the analysis period are determining your success factors (how do you know if your program works) and writing a specification of your program’s requirements.

Once you’ve analyzed the problem, you design the solution. Key to the design process is imagining the classes you will use and their inter-relationships. You might design a simple program on the fly, without this careful planning; but in any serious business application, you will want to take some time to think through the issues.

There are many powerful design techniques you might use, most of which are beyond the scope of this book. One interesting controversy that has arisen recently is between traditional object-oriented design on the one hand[7] and eXtreme programming on the other.[8]

There are other competing approaches as well. How much time you put into these topics will depend, in large measure, on the complexity of the problems you are trying to solve, and the size of your development team.

Tip

My personal approach to managing complexity is to keep team size very small. I have worked on large development teams, and over the years I’ve come to believe that the ideal size is three. Three highly skilled programmers can be incredibly productive, and with three you don’t need a manager. Three people can have only one conversation at a time. Three people can never be evenly split on a decision. One day I’ll write a book on programming in teams of three, but this isn’t it, and so we’ll stay focused on VB.NET programming, rather than on design debates.



[6] The Fibonacci series is the sum of the values 0,1,1,2,3,5,8,13... The series is named for Fibonacci, who in 1202 investigated how fast rabbits could breed in ideal circumstances. The series works by adding the previous two numbers to get the next (thus 8 is the sum of 5+3).

[7] See The Unified Modeling Language User Guide, The Unified Software Development Process, and The Unified Modeling Language Reference Manual, all by Grady Booch, Ivar Jacobson, and James Rumbaugh (Addison-Wesley).

[8] See Planning Extreme Programming by Kent Beck and Martin Fowler (Addison-Wesley).

Get Programming Visual Basic .NET, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.