Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


What are the other ways to create an object with out calling
new keyword in java?

Answers were Sorted based on User's Feedback



What are the other ways to create an object with out calling new keyword in java?..

Answer / bala

using in class.for name method
myobject obj=(my object)class.for name("sub in.rnd.my object").new instance();

Is This Answer Correct ?    1 Yes 0 No

What are the other ways to create an object with out calling new keyword in java?..

Answer / sumitpalsingh

1.by using newInstance();,but before this we have to load the class by using Class.forName();

myobject obj=(my object)class.for name("sub in.rnd.my object").new instance();

2.By using clone();
3.BY using DeSerialization.
ObjectInputStream inStream = new ObjectInputStream(anInputStream );
MyObject object = (MyObject) inStream.readObject();

4.By using String class .

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Programming Languages AllOther Interview Questions

How can we develop a multi-tier application in Java?

0 Answers  


What is the maximum amount of memory any single process on Windows can address? Is this different than the maximum virtual memory for the system? How would this affect a system design?

2 Answers  


what are the 3 forms of a prolog term

0 Answers  


8.In DSP,Define Signal and System?and various type of signals.

0 Answers  


Write a program to reverse a number?

0 Answers   BirlaSoft,


Difference between views and index in sas programming

0 Answers   Ventois,


what is the similarity between networking devices?

0 Answers   Cygnus, Infosys,


What is web.configuration? how is it work? & wht is use this?

0 Answers  


which property is used to display the advertisements with adrotator control

0 Answers   Sonata,


how will you code the subfile which is in editing mode (multiple case subfile)?

0 Answers   Bank Of America,


Which design patterns have you used?

0 Answers  


I need source code for Enrollment System using Visual Basic 6.0/2008 database MS Access 2007 for my school thesis project...please help me..kindly send in my email jpinedamcp@gmail.com

0 Answers  


Categories