src/jdk.jdeps/share/classes/com/sun/tools/jdeprscan/internals.md
author mchung
Fri, 23 Feb 2018 12:10:56 -0800
changeset 48942 a6c4b85163c1
parent 47216 71c04702a3d5
permissions -rw-r--r--
8198249: Remove deprecated Runtime::runFinalizersOnExit and System::runFinalizersOnExit Reviewed-by: dholmes, alanb, smarks
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
40596
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
     1
<!--
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
     2
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
     3
Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
     4
DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
     5
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
     6
This code is free software; you can redistribute it and/or modify it
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
     7
under the terms of the GNU General Public License version 2 only, as
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
     8
published by the Free Software Foundation.  Oracle designates this
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
     9
particular file as subject to the "Classpath" exception as provided
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    10
by Oracle in the LICENSE file that accompanied this code.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    11
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    12
This code is distributed in the hope that it will be useful, but WITHOUT
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    13
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    14
FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    15
version 2 for more details (a copy is included in the LICENSE file that
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    16
accompanied this code).
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    17
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    18
You should have received a copy of the GNU General Public License version
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    19
2 along with this work; if not, write to the Free Software Foundation,
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    20
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    21
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    22
Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    23
or visit www.oracle.com if you need additional information or have any
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    24
questions.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    25
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    26
-->
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    27
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    28
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    29
JDeprScan Internals
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    30
-----
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    31
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    32
**EXPERIMENTAL OPTIONS**
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    33
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    34
    --Xload-class CLASSNAME
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    35
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    36
        Loads deprecation data from the class named CLASSNAME instead of from
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    37
        the JDK image.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    38
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    39
    --Xload-csv CVSFILE
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    40
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    41
        Loads deprecation data from file CSVFILE.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    42
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    43
    --Xload-dir DIR
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    44
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    45
        Loads deprecation data from the class hierarchy rooted
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    46
        at the directory named DIR.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    47
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    48
    --Xload-jar JARFILE
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    49
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    50
        Loads deprecation data from the classes contained in the
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    51
        jar file named JARFILE.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    52
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    53
    --Xload-jdk9 JAVA_HOME
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    54
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    55
        Loads deprecation data from a modular JDK whose home
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    56
        directory is at JAVA_HOME. This essentially adds the given
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    57
        path to the system-modules location.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    58
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    59
    --Xload-old-jdk JAVA_HOME
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    60
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    61
        Loads deprecation data from an old (non-modular) JDK whose
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    62
        home directory is at JAVA_HOME. This essentially scans the
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    63
        rt.jar file from that JDK.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    64
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    65
    --Xload-self
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    66
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    67
        Loads deprecation data from the running JDK image by
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    68
        traversing the entire jrt: filesystem. This differs from
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    69
        -release 9, which traverses modules, packages, and classes by
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    70
        starting from a set of root modules and using javax.lang.model
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    71
        mechanisms (as opposed to filesystem mechanisms) for
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    72
        traversing contained elements recursively.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    73
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    74
    --Xcompiler-arg ARG
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    75
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    76
        Adds ARG to the list of arguments passed to the compiler.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    77
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    78
    --Xcsv-comment COMMENT
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    79
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    80
        Adds a comment line containing COMMENT to the top of the CSV
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    81
        that is emitted.  Valid only when --Xprint-csv is
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    82
        specified. More than one --Xcsv-comment option is permitted,
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    83
        which will cause a corresponding number of comment lines to be
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    84
        emitted to the CSV file.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    85
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    86
    --Xprint-csv
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    87
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    88
        Prints out the loaded deprecation information in CSV format
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    89
        to standard output. In this mode, no scanning is done, so
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    90
        there must not be any additional directory, jar, or classname
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    91
        arguments.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    92
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    93
**CSV FILE SYNTAX**
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    94
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    95
The `-Xprint-csv` option causes **jdeprscan** to emit the loaded
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    96
deprecation data in CSV (comma-separated value) format.  The general
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    97
syntax of CSV is documented in [RFC 4180][RFC] with supplemental
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    98
information in a [Wikipedia article][wiki].
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
    99
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   100
The file is encoded in UTF-8.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   101
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   102
The file consists of a series of lines. Any of the standard line
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   103
separators CR (U+000D), LF (U+000A), or a CR immediately followed by
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   104
LF, are supported. Newlines are only supported between records and
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   105
are not supported within field values.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   106
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   107
Comment lines start with a `#` (U+0023) character in the first
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   108
column. The entire line is ignored up until the next line separator
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   109
sequence.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   110
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   111
Each line is divided into fields separated by the comma `,` (U+002C)
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   112
character.  Horizontal whitespace is not treated specially; that is,
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   113
it is considered part of a field's value. An empty line is considered
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   114
to have one field which is the empty string.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   115
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   116
A field value that contains a comma or a quote quotation mark `"`
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   117
(U+0022) must be surrounded by quotation marks. The surrounding
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   118
quotation marks are not considered part of the field value. Any
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   119
quotation marks that are part of a field value must be repeated in
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   120
addition to being surrounded by quotation marks.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   121
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   122
It is a syntax error if a quotation mark appears within an unquoted field;
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   123
if a quoted field isn't immediately followed by a comma or line
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   124
separator; or if a quoted field is left unclosed at the end of the line.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   125
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   126
For example, a record with the following four fields:
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   127
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   128
1. abcd
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   129
2. ef,gh
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   130
3. ij"kl
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   131
4. mnop
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   132
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   133
would be encoded as follows:
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   134
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   135
        abcd,"ef,gh","ij""kl",mnop
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   136
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   137
**CSV FILE DATA**
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   138
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   139
The first line of output must be the following:
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   140
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   141
        #jdepr1
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   142
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   143
This is strictly a comment line, but it serves as a file
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   144
identifier. The "1" indicates version 1 of this file.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   145
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   146
Zero or more comment lines follow, containing text that is specified
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   147
by the `-Xcsv-comment` options.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   148
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   149
Subsequent non-comment lines must have the following five fields:
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   150
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   151
        kind,typeName,descOrName,since,forRemoval
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   152
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   153
Fields are defined as follows:
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   154
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   155
 * _kind_ - one of CONSTRUCTOR, FIELD, METHOD, ENUM\_CONSTANT,
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   156
   CLASS, INTERFACE, ENUM, or ANNOTATION\_TYPE. These correspond to
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   157
   enumeration constants from the `javax.lang.model.element.ElementKind`
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   158
   enum.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   159
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   160
 * _typeName_ - the fully qualified name of the type (if *kind* is
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   161
   CLASS, INTERFACE, ENUM, or ANNOTATION\_TYPE) or of the enclosing
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   162
   type (if _kind_ is CONSTRUCTOR, FIELD, METHOD, or
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   163
   ENUM\_CONSTANT). This value is a _binary name_ [JLS 13.1][jls131]
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   164
   using a slash character `/` (U+002F) to separate package and
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   165
   top-level name components, and a dollar sign `$` (U+0024) to
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   166
   separate nested name components. For example, the `Thread.State`
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   167
   enum that appears in Java SE would have the following typeName:
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   168
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   169
            java/lang/Thread$State
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   170
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   171
 * _descOrName_ - if _kind_ is METHOD or CONSTRUCTOR, this is the method's
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   172
   or constructor's descriptor [JVMS 4.3.3][jvms433]; if _kind_ is FIELD or
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   173
   ENUM\_CONSTANT, this is its name; otherwise this field is empty.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   174
   A method's descriptor includes its name, parameter types, and return
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   175
   type. For example, the method
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   176
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   177
           public void String.getBytes(int srcBegin,
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   178
                                       int srcEnd,
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   179
                                       byte[] dst,
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   180
                                       int dstBegin)
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   181
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   182
   has the descriptor
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   183
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   184
           getBytes(II[BI)V
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   185
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   186
 * _since_ - the value of the `since` element of the `@Deprecated`
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   187
   annotation, or empty if this element is not present.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   188
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   189
 * _forRemoval_ - the value of the `forRemoval` element of the
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   190
   `@Deprecated` annotation, a boolean, either "true" or "false".
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   191
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   192
Note that the _since_ field can have arbitrary text (excluding
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   193
line separators) and is thus subject to quoting.
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   194
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   195
**EXAMPLE OUTPUT**
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   196
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   197
Given the following method declaration and annotation from the
48942
a6c4b85163c1 8198249: Remove deprecated Runtime::runFinalizersOnExit and System::runFinalizersOnExit
mchung
parents: 47216
diff changeset
   198
`java.lang.Character` class,
40596
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   199
48942
a6c4b85163c1 8198249: Remove deprecated Runtime::runFinalizersOnExit and System::runFinalizersOnExit
mchung
parents: 47216
diff changeset
   200
            @Deprecated(since="1.1")
a6c4b85163c1 8198249: Remove deprecated Runtime::runFinalizersOnExit and System::runFinalizersOnExit
mchung
parents: 47216
diff changeset
   201
            public static boolean isJavaLetter(char ch)
40596
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   202
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   203
the following line will be emitted from **jdeprscan -Xprint-csv**:
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   204
48942
a6c4b85163c1 8198249: Remove deprecated Runtime::runFinalizersOnExit and System::runFinalizersOnExit
mchung
parents: 47216
diff changeset
   205
            METHOD,java/lang/Character,isJavaLetter(C)Z,1.1,false
40596
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   206
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   207
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   208
[RFC]: https://www.ietf.org/rfc/rfc4180.txt
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   209
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   210
[wiki]: https://en.wikipedia.org/wiki/Comma-separated_values
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   211
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   212
[jls131]: http://docs.oracle.com/javase/specs/jls/se8/html/jls-13.html#jls-13.1
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   213
43b19b36e8e6 8145464: implement deprecation static analysis tool
smarks
parents:
diff changeset
   214
[jvms433]: http://docs.oracle.com/javase/specs/jvms/se8/html/jvms-4.html#jvms-4.3.3