blob: 1913f691b3a211f2f9e5367835cfab9251ce7932 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<html> <head>
<title>AspectJ 6 Development Kit v1.6.0 Readme</title>
<style type="text/css">
<!--
P { margin-left: 20px; }
PRE { margin-left: 20px; }
LI { margin-left: 20px; }
H4 { margin-left: 20px; }
H3 { margin-left: 10px; }
-->
</style>
</head>
<body>
<div align="right"><small>
© Copyright 2006 Contributors.
All rights reserved.
</small></div>
<h1>AspectJ v1.6.0 Readme</h1>
<h3>AspectJ v1.6.0rc1- 16 Apr 2008</h3>
<p>This release candidate fixes a number of issues raised against M2 and earlier versions of AspectJ. The full list of fixes
is accessible here:
<a href="https://bugs.eclipse.org/bugs/buglist.cgi?query_format=advanced&short_desc_type=allwordssubstr&short_desc=&product=AspectJ&target_milestone=1.6.0+RC1&long_desc_type=allwordssubstr&long_desc=&bug_file_loc_type=allwordssubstr&bug_file_loc=&status_whiteboard_type=allwordssubstr&status_whiteboard=&keywords_type=allwords&keywords=&bug_status=RESOLVED&bug_status=VERIFIED&bug_status=CLOSED&emailtype1=substring&email1=&emailtype2=substring&email2=&bugidtype=include&bug_id=&votes=&chfieldfrom=&chfieldto=Now&chfieldvalue=&cmdtype=doit&order=Reuse+same+sort+as+last+time&field0-0-0=noop&type0-0-0=noop&value0-0-0=">1.6.0rc1 fixes</a>.
<p>It also includes some enhancements to incremental compilation support which enable AJDT to do incremental builds
more often than previously in a multi-project eclipse configuration.
These enhancements are described in <a href="https://bugs.eclipse.org/bugs/show_bug.cgi?id=221427">bug 221427</a>.
And some performance numbers are in <a href="http://dev.eclipse.org/mhonarc/lists/aspectj-users/msg09002.html">this mailing list</a> post.
<hr>
<h3>AspectJ v1.6.0M2 - 26 Feb 2008</h3>
<p>This milestone fixes a number of issues raised against M1 and earlier versions of AspectJ. The full list of fixes
is accessible here:
<a href="https://bugs.eclipse.org/bugs/buglist.cgi?query_format=advanced&short_desc_type=allwordssubstr&short_desc=&product=AspectJ&target_milestone=1.6.0+M2&long_desc_type=allwordssubstr&long_desc=&bug_file_loc_type=allwordssubstr&bug_file_loc=&status_whiteboard_type=allwordssubstr&status_whiteboard=&keywords_type=allwords&keywords=&bug_status=RESOLVED&bug_status=VERIFIED&bug_status=CLOSED&emailtype1=substring&email1=&emailtype2=substring&email2=&bugidtype=include&bug_id=&votes=&chfieldfrom=&chfieldto=Now&chfieldvalue=&cmdtype=doit&order=Reuse+same+sort+as+last+time&field0-0-0=noop&type0-0-0=noop&value0-0-0=">1.6.0m2 fixes</a>.
<p>1.6.0m2 includes two new features:
<ul>
<li>Parameter annotation matching</li>
<li>Annotation value matching</li>
</ul>
<p></p>
<h4>Parameter Annotation Matching</h4>
<p>Parameter matching is possible for constructors and methods. The use
of parentheses around the parameter types in a method signature
determine whether the annotations relate to the type of the parameter
or the parameter itself.
<pre><code>
execution(* *(@A *));
</code></pre>
<p>- Execution of a method/ctor whose first parameter is of a type
annotated with @A.
<pre><code>
execution(* *(@A (*)));
</code></pre>
<p>- Execution of a method/ctor whose first parameter is annotated with @A
<pre><code>
execution(* *(@A (@B *)))
</code></pre>
<p>- Execution of a method/ctor whose first parameter is annotated with
@A and is of a type annotated with @B.
Example:
<pre><code>
------ Start of Test.java -----
@interface A {}
@interface B {}
class C {
public void foo(@A String s) {}
public void goo(@A @B String s) {}
}
aspect X {
before(): execution(* *(@A (*))) {}
before(): execution(* *(@B (*))) {}
}
------ End of Test.java -----
$ ajc -showWeaveInfo -1.6 Test.java
Join point 'method-execution(void C.foo(java.lang.String))' in Type 'C' (A.java:5) advised by before advice from 'X' (A.java:10)
Join point 'method-execution(void C.goo(java.lang.String))' in Type 'C' (A.java:6) advised by before advice from 'X' (A.java:11)
Join point 'method-execution(void C.goo(java.lang.String))' in Type 'C' (A.java:6) advised by before advice from 'X' (A.java:10)
</code></pre>
<p>The first piece of advice matched both methods. The second only matched goo().
<br><br>
<h4>Annotation Value Matching</h4>
<p>This allows static matching of the values of an annotation - if the matching is done statically at weave time, it is possible
to avoid some of the reflection that is currently required within the advice (in some cases). A typical use case is tracing where
the trace level is defined by an annotation but may be switched OFF for a method if the annotation has a particular value. Perhaps
tracing has been turned on at the type level and a few critical methods should not get traced. Here is some code showing the
use case:
<p>
<pre><code>
enum TraceLevel { NONE, LEVEL1, LEVEL2, LEVEL3 }
@interface Trace {
TraceLevel value() default TraceLevel.LEVEL1;
}
aspect X {
// Advise all methods marked @Trace except those with a tracelevel of none
before(): execution(@Trace !@Trace(TraceLevel.NONE) * *(..)) {
System.err.println("tracing "+thisJoinPoint);
}
}
public class ExampleOne {
public static void main(String[] args) {
ExampleOne eOne = new ExampleOne();
eOne.m001();
eOne.m002();
eOne.m003();
eOne.m004();
eOne.m005();
eOne.m006();
eOne.m007();
}
@Trace(TraceLevel.NONE)
public void m001() {}
@Trace(TraceLevel.LEVEL2)
public void m002() {} // gets advised
@Trace(TraceLevel.LEVEL3)
public void m003() {} // gets advised
@Trace(TraceLevel.NONE)
public void m004() {}
@Trace(TraceLevel.LEVEL2)
public void m005() {} // gets advised
@Trace(TraceLevel.NONE)
public void m006() {}
@Trace
public void m007() {} // gets advised
}
</pre></code>
Matching is currently allowed on all annotation value types *except* class and array. Also it is
not currently supported for parameter annotation values.
<hr>
<h3>AspectJ v1.6.0M1 - 16 Jan 2008</h3>
<p>This is the first milestone release of AspectJ 6. AspectJ 6 is a Java 6 compiler,
the underlying Eclipse JDT compiler version upon which it is based is 785_R33x - a recent 3.3 version.</p>
<p>The compiler had changed a lot since version 574_R31x when we last merged!
This milestone passes the 3615 automated tests we have defined for AspectJ - but that does not mean it will work perfectly for you, if it does not then
please <a href="https://bugs.eclipse.org/bugs/enter_bug.cgi?product=AspectJ">raise a bug in bugzilla</a>.
<p>Issues:</p>
<ul>
<li>Open bugs targeted for fix by 1.6.0 final are <a href="https://bugs.eclipse.org/bugs/buglist.cgi?query_format=advanced&short_desc_type=allwordssubstr&short_desc=&product=AspectJ&target_milestone=1.6.0&long_desc_type=allwordssubstr&long_desc=&bug_file_loc_type=allwordssubstr&bug_file_loc=&status_whiteboard_type=allwordssubstr&status_whiteboard=&keywords_type=allwords&keywords=&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&emailtype1=substring&email1=&emailtype2=substring&email2=&bugidtype=include&bug_id=&votes=&chfieldfrom=&chfieldto=Now&chfieldvalue=&cmdtype=doit&order=Importance&field0-0-0=noop&type0-0-0=noop&value0-0-0=">listed here</a>.
<li>Bugs that have been opened upon this milestone are <a href="https://bugs.eclipse.org/bugs/buglist.cgi?query_format=advanced&short_desc_type=allwordssubstr&short_desc=&product=AspectJ&version=1.6.0M1&long_desc_type=allwordssubstr&long_desc=&bug_file_loc_type=allwordssubstr&bug_file_loc=&status_whiteboard_type=allwordssubstr&status_whiteboard=&keywords_type=allwords&keywords=&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&emailtype1=substring&email1=&emailtype2=substring&email2=&bugidtype=include&bug_id=&votes=&chfieldfrom=&chfieldto=Now&chfieldvalue=&cmdtype=doit&order=Reuse+same+sort+as+last+time&field0-0-0=noop&type0-0-0=noop&value0-0-0=">listed here</a>.
<li>Bugs that have been FIXED throughout 1.6.0 are <a href="https://bugs.eclipse.org/bugs/buglist.cgi?query_format=advanced&short_desc_type=allwordssubstr&short_desc=&product=AspectJ&target_milestone=1.6.0+M1&target_milestone=1.6.0+M2&target_milestone=1.6.0&long_desc_type=allwordssubstr&long_desc=&bug_file_loc_type=allwordssubstr&bug_file_loc=&status_whiteboard_type=allwordssubstr&status_whiteboard=&keywords_type=allwords&keywords=&bug_status=RESOLVED&bug_status=VERIFIED&bug_status=CLOSED&emailtype1=substring&email1=&emailtype2=substring&email2=&bugidtype=include&bug_id=&votes=&chfieldfrom=&chfieldto=Now&chfieldvalue=&cmdtype=doit&order=Reuse+same+sort+as+last+time&field0-0-0=noop&type0-0-0=noop&value0-0-0=">listed here</a>. The latest dev builds will include these fixes (the fixes may not be in the most recent milestone).
</ul>
<p>Known issues with this milestone:</p>
<ul>
<li>StackMapTable attributes not produced for all members, where they would normally be required.
<li>Distribution may currently contain some 'dead code' that we can remove, dependencies from compiler classes that are never actually used.
<li>No performance testing done
<li>No memory usage testing done
<li>Limited actual Java6 testing done, as I am on a Mac ;)
<li>Does not default to Java6 compilation (use -1.6 or -source 1.6)
</ul>
</p>
<p>Please test it and open any bugs you find!</p>
<br>
<hr>
</body>
</html>
|