/** * Verify if class or parent class has constant * * @param string $name * @return bool */ public function hasConstant($name) { if ($this->classScanner->hasConstant($name)) { return true; } foreach ($this->parentClassScanners as $pClassScanner) { if ($pClassScanner->hasConstant($name)) { return true; } } return false; }