ReflectionClass::isInternal
PHP function
Edit on GitHub ✎
(PHP 5, PHP 7, PHP 8)
Checks if class is defined internally by an extension, or the core
Description
ReflectionClass::isInternal(): bool
Checks if the class is defined internally by an extension, or the core, as opposed to user-defined.
Parameters Parameters
Return Values
Returns true if the class is defined internally by an extension or core, or false otherwise.
Examples
Basic usage of ReflectionClass::isInternal
php
<?php
$internalclass = new ReflectionClass('ReflectionClass');
class Apple {}
$userclass = new ReflectionClass('Apple');
var_dump($internalclass->isInternal());
var_dump($userclass->isInternal());
?>The above example will output:
output
bool(true)
bool(false)See Also
ReflectionClass::isUserDefined