Automattic\WooCommerce\Vendor\Symfony\Polyfill\Php80

Php80::get_resource_idpublic staticWC 1.0

Method of the class: Php80{}

No Hooks.

Returns

null. Nothing (null).

Usage

$result = Php80::get_resource_id( $res ): int;
$res(required)
.

Php80::get_resource_id() code WC 10.4.3

public static function get_resource_id($res): int
{
    if (!\is_resource($res) && null === @get_resource_type($res)) {
        throw new \TypeError(sprintf('Argument 1 passed to get_resource_id() must be of the type resource, %s given', get_debug_type($res)));
    }

    return (int) $res;
}