author | jjg |
Fri, 27 May 2016 13:06:58 -0700 | |
changeset 38617 | d93a7f64e231 |
parent 37938 | 42baa89d2156 |
permissions | -rw-r--r-- |
10 | 1 |
/* |
15385 | 2 |
* Copyright (c) 2003, 2013, 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 |
||
37938
42baa89d2156
8075703: jdk.javadoc module exports com.sun.tools.javadoc package which contains a lot of internal API.
jjg
parents:
25874
diff
changeset
|
26 |
package com.sun.tools.javadoc.main; |
10 | 27 |
|
28 |
import com.sun.javadoc.*; |
|
29 |
||
30 |
import com.sun.tools.javac.code.Type; |
|
31 |
||
32 |
||
33 |
/** |
|
34 |
* Abstract implementation of <code>Type</code>, with useful |
|
35 |
* defaults for the methods in <code>Type</code> (and a couple from |
|
36 |
* <code>ProgramElementDoc</code>). |
|
37 |
* |
|
14260
727a84636f12
8000665: fix "internal API" comments on javadoc files
jjg
parents:
14258
diff
changeset
|
38 |
* <p><b>This is NOT part of any supported API. |
727a84636f12
8000665: fix "internal API" comments on javadoc files
jjg
parents:
14258
diff
changeset
|
39 |
* If you write code that depends on this, you do so at your own risk. |
727a84636f12
8000665: fix "internal API" comments on javadoc files
jjg
parents:
14258
diff
changeset
|
40 |
* This code and its internal interfaces are subject to change or |
727a84636f12
8000665: fix "internal API" comments on javadoc files
jjg
parents:
14258
diff
changeset
|
41 |
* deletion without notice.</b> |
727a84636f12
8000665: fix "internal API" comments on javadoc files
jjg
parents:
14258
diff
changeset
|
42 |
* |
10 | 43 |
* @author Scott Seligman |
44 |
* @since 1.5 |
|
45 |
*/ |
|
38617 | 46 |
@Deprecated |
10 | 47 |
abstract class AbstractTypeImpl implements com.sun.javadoc.Type { |
48 |
||
49 |
protected final DocEnv env; |
|
50 |
protected final Type type; |
|
51 |
||
52 |
protected AbstractTypeImpl(DocEnv env, Type type) { |
|
53 |
this.env = env; |
|
54 |
this.type = type; |
|
55 |
} |
|
56 |
||
57 |
public String typeName() { |
|
58 |
return type.tsym.name.toString(); |
|
59 |
} |
|
60 |
||
61 |
public String qualifiedTypeName() { |
|
62 |
return type.tsym.getQualifiedName().toString(); |
|
63 |
} |
|
64 |
||
16969
b58d8a70d921
8009686: Generated javadoc documentation should be able to display type annotation on an array
bpatel
parents:
15385
diff
changeset
|
65 |
public com.sun.javadoc.Type getElementType() { |
b58d8a70d921
8009686: Generated javadoc documentation should be able to display type annotation on an array
bpatel
parents:
15385
diff
changeset
|
66 |
return null; |
b58d8a70d921
8009686: Generated javadoc documentation should be able to display type annotation on an array
bpatel
parents:
15385
diff
changeset
|
67 |
} |
b58d8a70d921
8009686: Generated javadoc documentation should be able to display type annotation on an array
bpatel
parents:
15385
diff
changeset
|
68 |
|
10 | 69 |
public String simpleTypeName() { |
70 |
return type.tsym.name.toString(); |
|
71 |
} |
|
72 |
||
73 |
public String name() { |
|
74 |
return typeName(); |
|
75 |
} |
|
76 |
||
77 |
public String qualifiedName() { |
|
78 |
return qualifiedTypeName(); |
|
79 |
} |
|
80 |
||
81 |
public String toString() { |
|
82 |
return qualifiedTypeName(); |
|
83 |
} |
|
84 |
||
85 |
public String dimension() { |
|
86 |
return ""; |
|
87 |
} |
|
88 |
||
89 |
public boolean isPrimitive() { |
|
90 |
return false; |
|
91 |
} |
|
92 |
||
93 |
public ClassDoc asClassDoc() { |
|
94 |
return null; |
|
95 |
} |
|
96 |
||
97 |
public TypeVariable asTypeVariable() { |
|
98 |
return null; |
|
99 |
} |
|
100 |
||
101 |
public WildcardType asWildcardType() { |
|
102 |
return null; |
|
103 |
} |
|
104 |
||
105 |
public ParameterizedType asParameterizedType() { |
|
106 |
return null; |
|
107 |
} |
|
108 |
||
109 |
public AnnotationTypeDoc asAnnotationTypeDoc() { |
|
110 |
return null; |
|
111 |
} |
|
15385 | 112 |
|
113 |
public AnnotatedType asAnnotatedType() { |
|
114 |
return null; |
|
115 |
} |
|
10 | 116 |
} |