-
- All Superinterfaces:
-
Mirror
- All Known Subinterfaces:
-
ArrayType,BooleanType,ByteType,CharType,ClassType,DoubleType,FloatType,IntegerType,InterfaceType,LongType,PrimitiveType,ReferenceType,ShortType,VoidType
public interface Type extends Mirror
目标VM中类型的镜像。 此接口是包含基元类型和引用类型的类型层次结构的根。Type可用于表示运行时类型:
或编译时类型:Value.type()Field.type()
Method.returnType()
Method.argumentTypes()
LocalVariable.type()
ArrayType.componentType()下表说明了Type的哪些子接口用于镜像目标VM中的类型 -
Subinterfaces ofPrimitiveTypeType declared in target as Is mirrored as an instance ofbooleanBooleanTypebyteByteTypecharCharTypedoubleDoubleTypefloatFloatTypeintIntegerTypelongLongTypeshortShortTypevoidVoidType
Subinterfaces ofReferenceTypeType declared in target as For example Is mirrored as an instance of a classDateClassTypean interfaceRunnableInterfaceTypean array (any)ArrayTypeint[]ArrayTypewhosecomponentType()isIntegerTypeDate[]ArrayTypewhosecomponentType()isClassTypeRunnable[]ArrayTypewhosecomponentType()isInterfaceType
-
-
方法详细信息
-
signature
String signature()
返回此类型的JNI样式签名。对于基本类,返回的签名是相应基元类型的签名; 例如,“I”作为由
Integer.TYPE表示的类的签名返回。- 结果
- 包含类型签名的字符串。
- 另请参见:
- Type Signatures
-
name
String name()
- 结果
- 这种类型的文本表示。
-
-