Code Spelunking in Java
Introduction: Seeking Code Roots
When it's your first day on a new maintenance task, your first goal is probably to get the thing running, as we discussed in last month's column. Your second goal is to try to make some sense out of the code base so that you can figure out where to start making changes.
Here are some questions you want to be able to answer about the program, as quickly as possible:
Where does it start running?
Which classes and methods are most central to the task at hand?
How do you create instances of those classes?