note 79891 added to language.oop.serialization

From: Date: Tue, 18 Dec 2007 10:02:26 +0000
Subject: note 79891 added to language.oop.serialization
Groups: php.notes 
Request: Send a blank email to php-notes+get-133748@lists.php.net to get a copy of this message
It's worth noting that when you serialize an object (after creating it normally), its __sleep method will be called, and then when the object naturally goes out of scope, it's __destruct method will also be called. However, when you unserialize an object, its __wakeup method will be called, but it's __construct method will not be called. I'm not quite sure if there's a way to force an object completely out of scope without having __destruct automatically be called. If there is though (and it's neat - not like invoking 'die' at the end of every page), I'd like to hear about it! ---- Server IP: 83.137.20.135 Probable Submitter: 62.58.16.165 ---- Manual Page -- http://www.php.net/manual/en/language.oop.serialization.php Edit -- https://master.php.net/note/edit/79891 Del: integrated -- https://master.php.net/note/delete/79891/integrated Del: useless -- https://master.php.net/note/delete/79891/useless Del: bad code -- https://master.php.net/note/delete/79891/bad+code Del: spam -- https://master.php.net/note/delete/79891/spam Del: non-english -- https://master.php.net/note/delete/79891/non-english Del: in docs -- https://master.php.net/note/delete/79891/in+docs Del: other reasons-- https://master.php.net/note/delete/79891 Reject -- https://master.php.net/note/reject/79891 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#133748) next »