lithium\analysis\Inspector::parents()
Gets the full inheritance list for the given class.
Parameters
-
string
$class
Class whose inheritance chain will be returned
-
array
$options
Option consists of:
'autoLoad'
boolean: Whether or not to call__autoload
by default. Defaults totrue
.
Returns
arrayAn array of the name of the parent classes of the passed $class
parameter,
or false
on error.
Links
Source
public static function parents($class, array $options = []) {
$defaults = ['autoLoad' => false];
$options += $defaults;
$class = is_object($class) ? get_class($class) : $class;
if (!$class || !class_exists($class, $options['autoLoad'])) {
return false;
}
return class_parents($class);
}