Hi
What is the exact difference between the Class.forName(Classname) and new classname
Here Class.forname () returns class object & new classname also returns specified class object. so wht is the exact difference b/w then?
Printable View
Hi
What is the exact difference between the Class.forName(Classname) and new classname
Here Class.forname () returns class object & new classname also returns specified class object. so wht is the exact difference b/w then?
Class.forName() decides what type of object is to be created at run-time.
It removes build-time dependency.