文档介绍:The Real Costs of Aspect-
Oriented Programming?
Roger Alexander
s a software developer, one of my prin- troduce new data and control dependencies
cipal objectives is to deliver the highest- into the primary concern and alter or even
quality software possible. Unfortunately, eliminate existing Indeed, the
as a human being, my abilities are also purpose of AspectJ’s around advice2 is to in-
my limitations, and I always make troduce a new control dependency into the
mistakes of one kind or another. To code at some well-defined location—a join
A 3
remedy this, I use tools to help ameliorate as point—JP in P. You plish this by sur-
many of my limitations as possible. One of my rounding the statements corresponding to JP
concerns is to understand how using a partic- with a statement C having a conditional expres-
ular tool affects my ability to meet objectives. sion that determines when or if the statements
How does it help with the various of JP execute in W. The statements in W corre-
software development tasks? What sponding to JP have e control-dependent
does it cost me to use a particular on C, whereas in P, these statements had no
tool? Do the benefits outweigh the such control dependency. So W’s behavior
costs? If so, what degree is the ben- with respect to JP is different from P.
efit? If not, then the tool is of little
use