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...

How can u create the Object of class Without using "New"
opertor?

Answer Posted / mohan reddy

In 3 ways we can able to create object without using "new"
operator.

1)Using a Static Factory Method
ABC.getInstance();
2)Using newInstance() method...
class A=(A)Class.forName("A").newInstance();
3)Using clone() method.

Is This Answer Correct ?    38 Yes 7 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why are constructors used?

967


What is the difference between class & structure?

1133


Which is dependent variable?

850


how are methods defined?

1000


What does jenkins do?

874


How to provide security in java

2203


What is the use of optional ?

991


what is meant by abstract class?

1073


Explain method overloading?

967


What are the different ways of implementing thread? Which one is more advantageous?

942


what is predefined function in java?

944


what is the use of bean managed and container managed with example?

1935


What is difference between static and final?

1018


what do you mean by classloader?

1033


What is the relationship between clipping and repainting under awt?

1100