Preface |
|
xv | |
Introduction |
|
xvii | |
|
Part 1 Introducing Eclipse, AspectJ, and AJDT |
|
|
1 | (130) |
|
|
3 | (18) |
|
|
3 | (1) |
|
|
3 | (2) |
|
|
5 | (6) |
|
|
11 | (8) |
|
|
19 | (1) |
|
|
20 | (1) |
|
|
21 | (44) |
|
A Simple Insurance Application |
|
|
21 | (5) |
|
|
26 | (3) |
|
Creating an AspectJ Project |
|
|
29 | (5) |
|
Creating the PolicyChangeNotification Aspect |
|
|
34 | (3) |
|
Stating the Notification Policy |
|
|
37 | (8) |
|
Implementing the Notification Policy |
|
|
45 | (5) |
|
|
50 | (4) |
|
Evaluating the Implementation |
|
|
54 | (7) |
|
|
61 | (1) |
|
|
62 | (3) |
|
Extending the Application |
|
|
65 | (46) |
|
|
66 | (2) |
|
Serialization-Based Persistence |
|
|
68 | (16) |
|
|
84 | (24) |
|
Managing Build Configurations |
|
|
108 | (2) |
|
|
110 | (1) |
|
|
111 | (20) |
|
Building an ASPECTJ Project |
|
|
111 | (5) |
|
|
116 | (7) |
|
Editor Templates and the Outline View Toolbar |
|
|
123 | (2) |
|
Generating Documentation (Ajdoc) |
|
|
125 | (2) |
|
AspectJ Help, Examples, and Cheat Sheets |
|
|
127 | (2) |
|
|
129 | (2) |
|
Part 2 The AspectJ Language |
|
|
131 | (224) |
|
|
133 | (14) |
|
|
133 | (3) |
|
Join Points and Pointcuts |
|
|
136 | (4) |
|
|
140 | (2) |
|
|
142 | (2) |
|
Key Design Properties of the AspectJ Language |
|
|
144 | (2) |
|
|
146 | (1) |
|
|
146 | (1) |
|
|
147 | (82) |
|
|
147 | (1) |
|
Introduction to Pointcut Designators |
|
|
148 | (1) |
|
The Method Call Pointcut Designator |
|
|
149 | (6) |
|
|
155 | (2) |
|
|
157 | (9) |
|
The Method Execution Pointcut Designator |
|
|
166 | (4) |
|
The Target Pointcut Designator |
|
|
170 | (6) |
|
The this Pointcut Designator |
|
|
176 | (3) |
|
The get and set Pointcut Designators |
|
|
179 | (7) |
|
/Capturing Context with the args Pointcut Designator |
|
|
186 | (6) |
|
Extracting Values with this and target |
|
|
192 | (3) |
|
The handler Pointcut Designator |
|
|
195 | (3) |
|
Initialization Pointcut Designators |
|
|
198 | (8) |
|
Static Scoping Pointcut Designators: within, withincode |
|
|
206 | (3) |
|
Dynamic Scoping Pointcut Designators: cflow, cflowbelow |
|
|
209 | (7) |
|
The adviceexecution Pointcut Designator |
|
|
216 | (3) |
|
The if Pointcut Designator |
|
|
219 | (4) |
|
How to Write a Good Pointcut |
|
|
223 | (1) |
|
|
224 | (3) |
|
|
227 | (2) |
|
|
229 | (44) |
|
The Different Types of Advice |
|
|
229 | (19) |
|
Advice Parameters and Pointcuts |
|
|
248 | (2) |
|
Writing Logic in the Body of Advice |
|
|
250 | (6) |
|
|
256 | (9) |
|
|
265 | (2) |
|
declare warning and declare error |
|
|
267 | (2) |
|
|
269 | (2) |
|
|
271 | (2) |
|
|
271 | (2) |
|
|
273 | (28) |
|
Fields, Methods, and Constructors |
|
|
274 | (8) |
|
|
282 | (3) |
|
Inter-Type Declarations and Interfaces |
|
|
285 | (12) |
|
|
297 | (1) |
|
Using Pointcuts and Advice with Inter-Type Declarations |
|
|
298 | (1) |
|
|
299 | (2) |
|
|
301 | (28) |
|
Aspect Definition and Initialization |
|
|
301 | (2) |
|
|
303 | (15) |
|
|
318 | (5) |
|
|
323 | (1) |
|
|
324 | (2) |
|
|
326 | (1) |
|
|
327 | (2) |
|
|
329 | (26) |
|
|
330 | (12) |
|
Package org.aspectj.lang.reflect |
|
|
342 | (11) |
|
|
353 | (2) |
|
Part 3 Putting It All Together |
|
|
355 | (92) |
|
|
357 | (58) |
|
|
357 | (4) |
|
Different Types of Aspects |
|
|
361 | (1) |
|
Enforcement Aspect Examples |
|
|
362 | (12) |
|
Infrastructure Aspect Examples |
|
|
374 | (27) |
|
|
401 | (11) |
|
Evaluating the Simple Insurance Application |
|
|
412 | (1) |
|
|
413 | (2) |
|
|
413 | (2) |
|
|
415 | (28) |
|
|
415 | (12) |
|
Linking Aspects with Compiled .class Files |
|
|
427 | (6) |
|
|
433 | (3) |
|
|
436 | (5) |
|
|
441 | (2) |
|
|
443 | (4) |
|
|
443 | (2) |
|
What Makes a Good Aspect? |
|
|
445 | (1) |
|
|
446 | (1) |
|
Appendix A Command-Line Aspect? |
|
|
447 | (6) |
|
|
447 | (1) |
|
|
448 | (2) |
|
|
450 | (3) |
|
Appendix B AspectJ Language Quick Reference |
|
|
453 | (8) |
|
|
453 | (1) |
|
|
454 | (3) |
|
|
457 | (1) |
|
|
457 | (2) |
|
B.5 Inter-Type Declarations |
|
|
459 | (2) |
|
|
461 | (6) |
|
|
461 | (3) |
|
Raising Bugs and Enhancement Requests |
|
|
464 | (1) |
|
Contributing to the Development of AspectJ and AJDT |
|
|
465 | (2) |
|
Appendix D AJDT Icons Reference |
|
|
467 | (4) |
|
|
467 | (2) |
|
|
469 | (1) |
|
|
469 | (1) |
|
|
470 | (1) |
Index |
|
471 | |