You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+8-4Lines changed: 8 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -7,11 +7,14 @@ The best analysis is performed using [external annotations](http://help.eclipse.
7
7
8
8
[This repository/project](https://github.com/sylvainlaurent/eclipse-external-annotations) contains a (non-exhaustive but growing) number of external annotations for usual classes (e.g. Map, List, some guava classes...).
9
9
10
-
To automatically associate an "annotation path" with the "Maven Dependencies" and "JRE" libraries in eclipse build path, install eclipse-external-annotations-m2e-plugin from [this p2 repository](http://sylvainlaurent.github.io/eclipse-external-annotations/p2/).
11
-
Then add a maven property `m2e.jdt.annotationpath` in your pom, as demonstrated in [with-external-annotations/pom.xml](with-external-annotations/pom.xml).
12
-
And finally perform a full `Maven/Update project...` in eclipse.
10
+
## Inside eclipse IDE
11
+
To automatically associate an "annotation path" with the "Maven Dependencies" and "JRE" libraries in eclipse build path:
12
+
- install eclipse-external-annotations-m2e-plugin from [this p2 repository](http://sylvainlaurent.github.io/eclipse-external-annotations/p2/).
13
+
- add a maven property `m2e.jdt.annotationpath` in your pom, as demonstrated in [with-external-annotations/pom.xml](with-external-annotations/pom.xml).
14
+
- perform a full `Maven/Update project...` in eclipse.
15
+
13
16
Tip: place the property in a `m2e` profile activated only inside eclipse, not in the command-line (see below for command-line usage).
14
-
Using a source project for external annotations in the same eclipse workspace allows to quickly add missing annotations directly from eclipse (by pressing Cmd-1 or Ctr-1 on the type of a method signature).
17
+
Using a source project for external annotations in the same eclipse workspace allows to quickly [add missing annotations directly from eclipse](http://help.eclipse.org/neon/topic/org.eclipse.jdt.doc.user/tasks/task-using_external_null_annotations.htm?cp=1_3_9_2_2#create).
15
18
16
19
```xml
17
20
<profile>
@@ -28,6 +31,7 @@ Using a source project for external annotations in the same eclipse workspace al
28
31
</profile>
29
32
```
30
33
34
+
## When running maven from the command-line
31
35
To perform null-analysis during a maven build, the jdt compiler must be used in place of the default javac, as demonstrated in the `not-m2e` maven profile of [with-external-annotations/pom.xml](with-external-annotations/pom.xml).
0 commit comments