suppose we have two object;obj1 and obj2
can we assign obj2 to one1;
and if yes; then after assigning suppose we delete obj2
then obj1 will retain obj2 value or not.
Answer Posted / masthan
see this example
parentclass obj1=new parentclass();
childclass obj2=obj1;//assign object to the reference of
childclass.here both obj1 and obj2 refer same memory
location.
obj1=null;//here obj1 losts the memory
console.write(obj2);//it refers same memory location
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Is it possible to write code in many languages in one asp.net project?
COM+ Used ________________ Isolation Level
Define repository pattern in asp.net mvc? : asp.net mvc
Which library is used by the testers and developers to develop automated tests and create testing tools?
What is a 404 redirect?
By default, Web API sends HTTP response with which of the following status code for all uncaught exception?
In ViewState How much lifespan items stored?
What is considered a service provider?
If you want to write your own dot net language, what steps you will you take care?
What is the difference between web config and machine config files?
Can I read the hard disk serial # of the client computer using asp.net?
Explain what the contents of cookie?
What is the difference between page-level caching and fragment caching?
How to do parallel database export in remote SQL Server in ESSL time track. It is working for local server but not working for remote SQL Server
Why session is necessary in web application?