I don't expect you to type along, but playing with the examples can be an interesting part of the experience. In addition to building the example application, I've provided plenty of usage details regarding development and production builds with AspectJ and how to organize the structure of a project with aspects. So, let's begin with the source organization (see Figure 3.2).
Figure 3.2 Project source tree.
The source tree contains several branches:
src/Java source files for all the business logic, security, persistence, and aspects. All Java source code is organized in packages; the directory structure down from this level corresponds to the package hierarchy as described here.
web/JSP pages for the AspectNews Web site. This is the document root of the AspectNews application.
web/WEB-INF/Configuration files for the application, including the Web application deployment descriptor and the tag library descriptor.
build/Temporary directory where the results of the build process are stored. This directory will be used to create a deployable copy of the AspectNews Web application.
sql/The directory for SQL scripts used to create and populate the database.
Java sources are divided into several packages:
introfor the examples shown in Part I of the book, "Introduction to Programming with AspectJ"
dbfor the database related classes
securityfor all security code
tagsfor all presentation JSP tags
languagefor the examples in Part III, "Language Details"
wrongfor the examples that should not work