What is the purpose of destructor ?

Answers were Sorted based on User's Feedback



What is the purpose of destructor ?..

Answer / sloog

Because destructors are are called when objects are
destroyed, they can be used for flushing a resource or
logging information on object destruction.

Is This Answer Correct ?    10 Yes 1 No

What is the purpose of destructor ?..

Answer / sunil kumar

A destructor is used to destroy the objects that have been
created earlier.Destructor is a member function whose name
is the same as the class name but is preceded by tilde sign.
It never takes any argument nor it returns any value.It`ll
be invoked implicitly by the compiler upon exit from the
program to clean up storage that is no longer accessible.

Is This Answer Correct ?    1 Yes 3 No

Post New Answer

More PHP Interview Questions

Is it possible to get the screen resolution and like with php?

1 Answers  


Give any ten basic functions in PHP?

4 Answers   T3 Softwares,


Which function can be used to delete a file?

0 Answers  


How can we destroy the session, how can we unset the variable of a session?

5 Answers  


Which php mvc framework is best?

0 Answers  






How do you check if a variable has not been set in php?

0 Answers  


What is the most convenient hashing method to be used to hash passwords?

0 Answers  


Why session is required?

0 Answers  


how do we can copy of the content of a web page with the help og the URL and display them onto any other page

5 Answers  


Which is better wamp or xampp?

0 Answers  


Tell me what does pear stands for?

0 Answers  


Why delimiter is used in mysql?

0 Answers  


Categories