Class Objects
Earlier we learned that each static method and static variable is accessed through the
class that defines it. For example, to access the static variable maxCalories, which is
defined by the VirtualPet class, we use the following code:
VirtualPet.maxCalories
In the preceding code, the use of the class name VirtualPet is not merely a matter of
syntax; VirtualPet actually refers to an object that defines the variable maxCalories.
The object referenced by VirtualPet is an automatically created instance of the builtin
Class class.