posted 23 years ago
Hi,
I am giving a little more important information about private.
First you have to know what is access modifier. There are four
important access modifier:
private
public
protected
package access
public : Anybody can create an instance of your class.
In turn, if you use private modifier, no other
class can instantiate your class as an object.
Your class can still contain public class methods,
and those methods can construct an object and
return it, but no one else can.
Thanks,
Golam Sayeed Newaz