-  
       
- All Superinterfaces:
 -  
         
AnnotatedConstruct,ReferenceType,TypeMirror 
public interface TypeVariable extends ReferenceType
表示类型变量。 类型变量可以由类型,方法或构造函数的type parameter显式声明。 类型变量也可以隐式声明,如通过通配符类型参数的捕获转换(参见The Java™ Language Specification的第5章)。- 从以下版本开始:
 - 1.6
 - 另请参见:
 -  
         
TypeParameterElement 
 
-  
        
       
-  
             
方法摘要
所有方法 实例方法 抽象方法 变量和类型 方法 描述 ElementasElement()返回与此类型变量对应的元素。TypeMirrorgetLowerBound()返回此类型变量的下限。TypeMirrorgetUpperBound()返回此类型变量的上限。-  
               
声明方法的接口 javax.lang.model.AnnotatedConstruct
getAnnotation, getAnnotationMirrors, getAnnotationsByType 
 -  
               
 
 -  
             
 
-  
        
       
-  
             
方法详细信息
-  
asElement
Element asElement()
返回与此类型变量对应的元素。- 结果
 - 与此类型变量对应的元素
 
 
-  
getUpperBound
TypeMirror getUpperBound()
返回此类型变量的上限。如果声明此类型变量没有显式上限,则结果为
java.lang.Object。 如果声明了多个上限,则结果为intersection type ; 通过检查结果bounds可以找到单个边界。- 结果
 - 此类型变量的上限
 
 
-  
getLowerBound
TypeMirror getLowerBound()
- 结果
 - the lower bound of this type variable
 
 
 -  
 
 -