| Author |
about Object declaration as static
|
Anand Natraj
Ranch Hand
Joined: May 17, 2004
Posts: 53
|
|
|
Can we declare an object of class as Static.If it can be declared static what is it's use
|
 |
Rachel Swailes
Ranch Hand
Joined: May 18, 2004
Posts: 434
|
|
|
You will see that you cannot declare a static class.
|
 |
Jeffrey Hunter
Ranch Hand
Joined: Apr 16, 2004
Posts: 305
|
|
The method readMe() belongs to the class, and not any particular instance of the class. Realize, you can have nested member classes (classes declared in body of top-level class), which may be static. But this follows the same idea that, when dealing with classes, only members of the class can be declared static. You can get a better grip on this idea by reading a definition of the static modifier here. [ June 07, 2004: Message edited by: Jeffrey Hunter ]
|
 |
 |
|
|
subject: about Object declaration as static
|
|
|