Java Reference
In-Depth Information
8.2.
Void
The
Void
class is the exception to all the preceding rules because it has
no values to wrap, provides no methods, and cannot be instantiated.
It has only a static
TYPE
field containing a reference to the
Class
object
void.class
. The language has no
void
type
void
is a placeholder indicating
no return type. The
Void
class represents that lack of an actual return
type and is only used in reflection (see "
The Method Class
"
on page
420
)
.