public function StaticReflectionParser::getStaticReflectionParserForDeclaringClass in Service Container 7
Same name and namespace in other branches
- 7.2 modules/providers/service_container_annotation_discovery/lib/Doctrine/common/lib/Doctrine/Common/Reflection/StaticReflectionParser.php \Doctrine\Common\Reflection\StaticReflectionParser::getStaticReflectionParserForDeclaringClass()
Gets the PSR-0 parser for the declaring class.
Parameters
string $type The type: 'property' or 'method'.:
string $name The name of the property or method.:
Return value
StaticReflectionParser A static reflection parser for the declaring class.
Throws
ReflectionException
File
- modules/
providers/ service_container_annotation_discovery/ lib/ Doctrine/ common/ lib/ Doctrine/ Common/ Reflection/ StaticReflectionParser.php, line 296
Class
- StaticReflectionParser
- Parses a file for namespaces/use/class declarations.
Namespace
Doctrine\Common\ReflectionCode
public function getStaticReflectionParserForDeclaringClass($type, $name) {
$this
->parse();
if (isset($this->docComment[$type][$name])) {
return $this;
}
if (!empty($this->parentClassName)) {
return $this
->getParentStaticReflectionParser()
->getStaticReflectionParserForDeclaringClass($type, $name);
}
throw new ReflectionException('Invalid ' . $type . ' "' . $name . '"');
}