What are the other ways to create an object with out calling
new keyword in java?
Answer Posted / 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 View All Answers
How to set on/off a group of indicators in a single statement?
10.Define filters,binary to hexadecimal,hexadecimal to decimal?
I have try to write a record in a TDQ from a fle.... what are the steps to do... can anybody plz come with a solution
What is the first message line that any language learning prints on the screen? and why?
Define distributed queries. can you explain me as soon as possible
hi i am jyoti i have done sap training in sd and master degree in economics have 2 year exp as enduser in (gdms)and 1 year as sd consultant.as contract basis now what i can do for getting job in it industry
How to call a C++ function which is compiled with C++ compiler in C code?
what is session state?
When we have two versions of the dot net installed how does the compiler know which version of DLL it has to select to an application.
If i have a dataset queried from Sql and I would like to insert the dataset into a specific node in an xml document how do I do this
what is delegate and how works delegate and event.
WHat is execution in manual testing and when will we start execution and what language we use in execution
what is the difference between Windows application and Unix application?
How can recruiter justified that the candidate is expert in Algorithm and datastructure for Software product development ?
What is dialog programming?