W3cubDocs

/PHP

WeakReference::get

(PHP 7 >= 7.4.0)

WeakReference::getGet a weakly referenced Object

Description

public WeakReference::get ( ) : object|null

Gets a weakly referenced object. If the object has already been destroyed, null is returned.

Parameters

This function has no parameters.

Return Values

Returns the referenced object, or null if the object has been destroyed.

© 1997–2020 The PHP Documentation Group
Licensed under the Creative Commons Attribution License v3.0 or later.
https://www.php.net/manual/en/weakreference.get.php