(PHP 8)
get_resource_id — Returns an integer identifier for the given resource
get_resource_id ( resource $res ) : int
This function provides a type-safe way for generating the integer identifier for a resource.
res
The evaluated resource handle.
The int identifier for the given res
.
This function is essentially an int cast of res
to make it easier to retrieve the resource ID.
© 1997–2020 The PHP Documentation Group
Licensed under the Creative Commons Attribution License v3.0 or later.
https://www.php.net/manual/en/function.get-resource-id.php