Is interface a reference type in Java

The type of an object in a target VM. ReferenceType encompasses classes, interfaces, and array types as defined in The Java™ Language Specification. All ReferenceType objects belong to one of the following subinterfaces: for classes, for interfaces, and for arrays. Note that primitive classes (for example, the of ) are represented as ClassType. The VM creates Class objects for all three, so from the VM perspective, each ReferenceType maps to a distinct Class object.

ReferenceTypes can be obtained by querying a particular for its type or by getting a list of all reference types from the .

ReferenceType provides access to static type information such as methods and fields and provides access to dynamic type information such as the corresponding Class object and the classloader.

Any method on which directly or indirectly takes as an parameter may throw if the target VM is disconnected and the has been or is available to be read from the .

Any method on which directly or indirectly takes as an parameter may throw if the target VM has run out of memory.

Any method on or which directly or indirectly takes as parameter may throw if the mirrored type has been unloaded.

Since:
1.3
See Also:
, , ,