5865
|
1 |
." Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved.
|
2
|
2 |
." DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
3 |
."
|
|
4 |
." This code is free software; you can redistribute it and/or modify it
|
|
5 |
." under the terms of the GNU General Public License version 2 only, as
|
|
6 |
." published by the Free Software Foundation.
|
|
7 |
."
|
|
8 |
." This code is distributed in the hope that it will be useful, but WITHOUT
|
|
9 |
." ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
10 |
." FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
|
11 |
." version 2 for more details (a copy is included in the LICENSE file that
|
|
12 |
." accompanied this code).
|
|
13 |
."
|
|
14 |
." You should have received a copy of the GNU General Public License version
|
|
15 |
." 2 along with this work; if not, write to the Free Software Foundation,
|
|
16 |
." Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
|
17 |
."
|
5506
|
18 |
." Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
|
19 |
." or visit www.oracle.com if you need additional information or have any
|
|
20 |
." questions.
|
2692
|
21 |
."
|
5865
|
22 |
.TH apt 1 "02 Jun 2010"
|
2
|
23 |
|
|
24 |
.LP
|
|
25 |
.SH "NAME"
|
|
26 |
.LP
|
|
27 |
.LP
|
|
28 |
\f2apt\fP \- annotation processing tool
|
|
29 |
.LP
|
|
30 |
.SH "SYNOPSIS"
|
|
31 |
.LP
|
|
32 |
.LP
|
|
33 |
\f2apt [\-classpath \fP\f2classpath\fP] [\-sourcepath \f2sourcepath\fP] [\-d \f2directory\fP] [\-s \f2directory\fP] [\-factorypath \f2path\fP] [\-factory \f2class\fP] [\-print] [\-nocompile] [\-A\f2key\fP[\f2=val\fP] ...] [\f2javac option\fP] sourcefiles [@files]
|
|
34 |
.LP
|
|
35 |
.SH "PARAMETERS"
|
|
36 |
.LP
|
|
37 |
.LP
|
|
38 |
Options may be in any order. For a discussion of parameters which apply to a specific option, see OPTIONS below.
|
|
39 |
.LP
|
2692
|
40 |
.RS 3
|
2
|
41 |
.TP 3
|
|
42 |
sourcefiles
|
|
43 |
Zero or more source files to be processed.
|
|
44 |
.TP 3
|
|
45 |
@files
|
|
46 |
One or more files that list source files or other options
|
2692
|
47 |
.RE
|
|
48 |
|
2
|
49 |
.LP
|
|
50 |
.SH "DESCRIPTION"
|
|
51 |
.LP
|
|
52 |
.LP
|
|
53 |
The tool \f2apt\fP, annotation processing tool, includes a set of new reflective APIs and supporting infrastructure to process program annotations. The \f2apt\fP reflective APIs provide a build\-time, source\-based, read\-only view of program structure. These reflective APIs are designed to cleanly model the Java(TM) programming language's type system after the addition of generics. First, \f2apt\fP runs annotation processors that can produce new source code and other files. Next, \f2apt\fP can cause compilation of both original and generated source files, easing development. The reflective APIs and other APIs used to interact with the tool are subpackages of \f2com.sun.mirror\fP.
|
|
54 |
.LP
|
|
55 |
.LP
|
|
56 |
A fuller discussion of how the tool operates as well as instructions for developing with \f2apt\fP are in
|
|
57 |
.na
|
|
58 |
\f4Getting Started with \fP\f4apt\fP. @
|
|
59 |
.fi
|
|
60 |
http://java.sun.com/javase/6/docs/technotes/guides/apt/GettingStarted.html
|
|
61 |
.LP
|
2692
|
62 |
.RS 3
|
2
|
63 |
.TP 3
|
|
64 |
Note:
|
2692
|
65 |
\f2The functionality of \fP\f2apt\fP has been subsumed by the annotation\-processing infrastructure that is now part of the \f2javac(1)\fP tool and standardized for use by all Java compilers. This new infrastructure relies on the language model and annotation\-processing APIs that are now part of the Java Platform. It is recommended that new annotation processor development be based on the new APIs and the \f2javac\fP tool.
|
|
66 |
.RE
|
|
67 |
|
2
|
68 |
.LP
|
|
69 |
.SH "OPTIONS"
|
|
70 |
.LP
|
|
71 |
.SS
|
|
72 |
apt specific options
|
|
73 |
.LP
|
2692
|
74 |
.RS 3
|
2
|
75 |
.TP 3
|
|
76 |
\-s dir
|
|
77 |
Specify the directory root under which processor\-generated source files will be placed; files are placed in subdirectories based on package namespace.
|
|
78 |
.TP 3
|
|
79 |
\-nocompile
|
|
80 |
Do not compile source files to class files.
|
|
81 |
.TP 3
|
|
82 |
\-print
|
|
83 |
Print out textual representation of specified types; perform no annotation processing or compilation.
|
|
84 |
.TP 3
|
|
85 |
\-A[key[=val]]
|
|
86 |
Options to pass to annotation processors \-\- these are not interpreted by \f2apt\fP directly, but are made available for use by individual processors
|
|
87 |
.TP 3
|
|
88 |
\-factorypath path
|
|
89 |
Specify where to find annotation processor factories; if this option is used, the classpath is \f2not\fP searched for factories.
|
|
90 |
.TP 3
|
|
91 |
\-factory classname
|
|
92 |
Name of annotation processor factory to use; bypasses default discovery process
|
2692
|
93 |
.RE
|
|
94 |
|
2
|
95 |
.LP
|
|
96 |
.SS
|
|
97 |
Options shared with javac
|
|
98 |
.LP
|
2692
|
99 |
.RS 3
|
2
|
100 |
.TP 3
|
|
101 |
\-d dir
|
|
102 |
Specify where to place processor and javac generated class files
|
|
103 |
.TP 3
|
2692
|
104 |
\-cp path or \-classpath path
|
2
|
105 |
Specify where to find user class files and annotation processor factories. If \f2\-factorypath\fP is given, the classpath is not searched for factories.
|
2692
|
106 |
.RE
|
|
107 |
|
2
|
108 |
.LP
|
|
109 |
.LP
|
|
110 |
Consult the javac(1) man page for information on \f2javac\fP options.
|
|
111 |
.LP
|
|
112 |
.SH "NOTES"
|
|
113 |
.LP
|
|
114 |
.LP
|
|
115 |
The functionality of \f2apt\fP has been subsumed by the standard annotation\-processing infrastructure now offered by \f2javac\fP. Support for \f2apt\fP and its associated APIs may be discontinued in some future JDK release.
|
|
116 |
.LP
|
|
117 |
.SH "SEE ALSO"
|
|
118 |
.LP
|
|
119 |
.RS 3
|
|
120 |
.TP 2
|
2692
|
121 |
o
|
|
122 |
javac(1), java(1)
|
2
|
123 |
.RE
|
|
124 |
|
|
125 |
.LP
|
|
126 |
|