author | naoto |
Tue, 29 Mar 2016 17:06:33 -0700 | |
changeset 36739 | 145210aba850 |
parent 25874 | 83c19f00452c |
child 38617 | d93a7f64e231 |
permissions | -rw-r--r-- |
10 | 1 |
/* |
23136
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
2 |
* Copyright (c) 1998, 2014, Oracle and/or its affiliates. All rights reserved. |
10 | 3 |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 |
* |
|
5 |
* This code is free software; you can redistribute it and/or modify it |
|
6 |
* under the terms of the GNU General Public License version 2 only, as |
|
5520 | 7 |
* published by the Free Software Foundation. Oracle designates this |
10 | 8 |
* particular file as subject to the "Classpath" exception as provided |
5520 | 9 |
* by Oracle in the LICENSE file that accompanied this code. |
10 | 10 |
* |
11 |
* This code is distributed in the hope that it will be useful, but WITHOUT |
|
12 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|
13 |
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
|
14 |
* version 2 for more details (a copy is included in the LICENSE file that |
|
15 |
* accompanied this code). |
|
16 |
* |
|
17 |
* You should have received a copy of the GNU General Public License version |
|
18 |
* 2 along with this work; if not, write to the Free Software Foundation, |
|
19 |
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
|
20 |
* |
|
5520 | 21 |
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
22 |
* or visit www.oracle.com if you need additional information or have any |
|
23 |
* questions. |
|
10 | 24 |
*/ |
25 |
||
26 |
package com.sun.javadoc; |
|
27 |
||
28 |
/** |
|
29 |
* Represents a java program element: class, interface, field, |
|
30 |
* constructor, or method. |
|
31 |
* This is an abstract class dealing with information common to |
|
32 |
* these elements. |
|
33 |
* |
|
34 |
* @see MemberDoc |
|
35 |
* @see ClassDoc |
|
36 |
* |
|
37 |
* @author Robert Field |
|
38 |
*/ |
|
39 |
public interface ProgramElementDoc extends Doc { |
|
40 |
||
41 |
/** |
|
42 |
* Get the containing class or interface of this program element. |
|
43 |
* |
|
44 |
* @return a ClassDoc for this element's containing class or interface. |
|
45 |
* If this is a top-level class or interface, return null. |
|
46 |
*/ |
|
47 |
ClassDoc containingClass(); |
|
48 |
||
49 |
/** |
|
50 |
* Get the package that this program element is contained in. |
|
51 |
* |
|
52 |
* @return a PackageDoc for this element containing package. |
|
53 |
* If in the unnamed package, this PackageDoc will have the |
|
54 |
* name "". |
|
55 |
*/ |
|
56 |
PackageDoc containingPackage(); |
|
57 |
||
58 |
/** |
|
59 |
* Get the fully qualified name of this program element. |
|
23136
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
60 |
* For example, for the class {@code java.util.Hashtable}, |
10 | 61 |
* return "java.util.Hashtable". |
62 |
* <p> |
|
23136
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
63 |
* For the method {@code bar()} in class {@code Foo} |
10 | 64 |
* in the unnamed package, return "Foo.bar". |
65 |
* |
|
66 |
* @return the qualified name of the program element as a String. |
|
67 |
*/ |
|
68 |
String qualifiedName(); |
|
69 |
||
70 |
/** |
|
71 |
* Get the modifier specifier integer. |
|
72 |
* |
|
73 |
* @see java.lang.reflect.Modifier |
|
23136
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
74 |
* |
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
75 |
* @return Get the modifier specifier integer. |
10 | 76 |
*/ |
77 |
int modifierSpecifier(); |
|
78 |
||
79 |
/** |
|
80 |
* Get modifiers string. |
|
81 |
* For example, for: |
|
82 |
* <pre> |
|
83 |
* public abstract int foo() { ... } |
|
84 |
* </pre> |
|
85 |
* return "public abstract". |
|
86 |
* Annotations are not included. |
|
23136
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
87 |
* |
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
88 |
* @return "public abstract". |
10 | 89 |
*/ |
90 |
String modifiers(); |
|
91 |
||
92 |
/** |
|
93 |
* Get the annotations of this program element. |
|
94 |
* Return an empty array if there are none. |
|
95 |
* |
|
96 |
* @return the annotations of this program element. |
|
97 |
* @since 1.5 |
|
98 |
*/ |
|
99 |
AnnotationDesc[] annotations(); |
|
100 |
||
101 |
/** |
|
102 |
* Return true if this program element is public. |
|
23136
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
103 |
* |
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
104 |
* @return true if this program element is public. |
10 | 105 |
*/ |
106 |
boolean isPublic(); |
|
107 |
||
108 |
/** |
|
109 |
* Return true if this program element is protected. |
|
23136
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
110 |
* |
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
111 |
* @return true if this program element is protected. |
10 | 112 |
*/ |
113 |
boolean isProtected(); |
|
114 |
||
115 |
/** |
|
116 |
* Return true if this program element is private. |
|
23136
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
117 |
* |
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
118 |
* @return true if this program element is private. |
10 | 119 |
*/ |
120 |
boolean isPrivate(); |
|
121 |
||
122 |
/** |
|
123 |
* Return true if this program element is package private. |
|
23136
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
124 |
* |
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
125 |
* @return true if this program element is package private. |
10 | 126 |
*/ |
127 |
boolean isPackagePrivate(); |
|
128 |
/** |
|
129 |
* Return true if this program element is static. |
|
23136
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
130 |
* |
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
131 |
* @return true if this program element is static. |
10 | 132 |
*/ |
133 |
boolean isStatic(); |
|
134 |
||
135 |
/** |
|
136 |
* Return true if this program element is final. |
|
23136
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
137 |
* |
aa8958a4c8f4
8035877: javadoc classes are missing @return and @param tags
jjg
parents:
5520
diff
changeset
|
138 |
* @return true if this program element is final. |
10 | 139 |
*/ |
140 |
boolean isFinal(); |
|
141 |
} |