Serialization of references to objects
| From: | Jonathan Sharp | Date: | Sun, 17 Nov 2002 06:27:45 +0000 |
| Subject: | Serialization of references to objects | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-124773@lists.php.net to get a copy of this message | ||
How is serialization of references handled? Example:
class foo
{
var $abc;
function bar()
{
echo $this->abc;
}
}
$obj = array( &new foo(), &new foo() );
$baz = serialize($obj);
/* ... dancing monkey for entertainment while time passes ... */
$obj = unserialize($baz);
Will references be restored upon unserialization?
-js