|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sun.tools.javac.code.Type
com.sun.tools.javac.code.Type.MethodType
public static class Type.MethodType
Nested Class Summary |
---|
Nested classes/interfaces inherited from class com.sun.tools.javac.code.Type |
---|
Type.ArrayType, Type.BottomType, Type.CapturedType, Type.ClassType, Type.DelegatedType, Type.ErasedClassType, Type.ErrorType, Type.ForAll, Type.JCNoType, Type.Mapping, Type.MethodType, Type.PackageType, Type.TypeVar, Type.UndetVar, Type.Visitor<R,S>, Type.WildcardType |
Field Summary | |
---|---|
List<Type> |
argtypes
|
Type |
restype
|
List<Type> |
thrown
|
Fields inherited from class com.sun.tools.javac.code.Type |
---|
moreInfo, noType, tag, tsym |
Constructor Summary | |
---|---|
Type.MethodType(List<Type> argtypes,
Type restype,
List<Type> thrown,
Symbol.TypeSymbol methodClass)
|
Method Summary | ||
---|---|---|
|
accept(Type.Visitor<R,S> v,
S s)
|
|
|
accept(TypeVisitor<R,P> v,
P p)
Applies a visitor to this type. |
|
Symbol.TypeSymbol |
asElement()
|
|
Type.MethodType |
asMethodType()
The underlying method type of this type. |
|
void |
complete()
Complete loading all classes in this type. |
|
boolean |
contains(Type elem)
Does this type contain occurrences of type t? |
|
boolean |
equals(java.lang.Object obj)
This method is analogous to isSameType, but weaker, since we never complete classes. |
|
TypeKind |
getKind()
Returns the kind of this type. |
|
List<Type> |
getParameterTypes()
Returns the types of this executable's formal parameters. |
|
Type |
getReturnType()
Returns the return type of this executable. |
|
List<Type> |
getThrownTypes()
Returns the exceptions and other throwables listed in this executable's throws clause. |
|
List<Type.TypeVar> |
getTypeVariables()
Returns the type variables declared by the formal type parameters of this executable. |
|
int |
hashCode()
Obeys the general contract of Object.hashCode . |
|
boolean |
isErroneous()
Does this type contain "error" elements? |
|
Type |
map(Type.Mapping f)
map a type function over all immediate descendants of this type |
|
void |
setThrown(List<Type> t)
|
|
java.lang.String |
toString()
The Java source which this type represents. |
Methods inherited from class com.sun.tools.javac.code.Type |
---|
allparams, argtypes, baseType, baseTypes, clone, constType, constValue, contains, containsSome, getEnclosingType, getLowerBound, getTypeArguments, getUpperBound, isCompound, isErroneous, isExtendsBound, isFalse, isInterface, isParameterized, isPrimitive, isRaw, isSuperBound, isTrue, isUnbound, map, stringValue, toString, withTypeVar |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public List<Type> argtypes
public Type restype
public List<Type> thrown
Constructor Detail |
---|
public Type.MethodType(List<Type> argtypes, Type restype, List<Type> thrown, Symbol.TypeSymbol methodClass)
Method Detail |
---|
public <R,S> R accept(Type.Visitor<R,S> v, S s)
accept
in class Type
public java.lang.String toString()
toString
in interface TypeMirror
toString
in class Type
public boolean equals(java.lang.Object obj)
Type
equals
in interface TypeMirror
equals
in class Type
obj
- the object to be compared with this type
true
if the specified object is equal to this onepublic int hashCode()
TypeMirror
Object.hashCode
.
hashCode
in interface TypeMirror
hashCode
in class Type
TypeMirror.equals(java.lang.Object)
public List<Type> getParameterTypes()
ExecutableType
getParameterTypes
in interface ExecutableType
getParameterTypes
in class Type
public Type getReturnType()
ExecutableType
NoType
with kind VOID
if this executable is not a method, or is a method that does not
return a value.
getReturnType
in interface ExecutableType
getReturnType
in class Type
public List<Type> getThrownTypes()
ExecutableType
throws
clause.
getThrownTypes
in interface ExecutableType
getThrownTypes
in class Type
throws
clause,
or an empty list if there are none.public void setThrown(List<Type> t)
setThrown
in class Type
public boolean isErroneous()
Type
isErroneous
in class Type
public Type map(Type.Mapping f)
Type
map
in class Type
public boolean contains(Type elem)
Type
contains
in class Type
public Type.MethodType asMethodType()
Type
asMethodType
in class Type
public void complete()
Type
complete
in class Type
public List<Type.TypeVar> getTypeVariables()
ExecutableType
getTypeVariables
in interface ExecutableType
public Symbol.TypeSymbol asElement()
asElement
in class Type
public TypeKind getKind()
TypeMirror
kind
of this type.
getKind
in interface TypeMirror
getKind
in class Type
public <R,P> R accept(TypeVisitor<R,P> v, P p)
TypeMirror
accept
in interface TypeMirror
accept
in class Type
R
- the return type of the visitor's methodsP
- the type of the additional parameter to the visitor's methodsv
- the visitor operating on this typep
- additional parameter to the visitor
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |