function DocParser::setImports
Sets the imports.
Parameters
array $imports:
Return value
void
Throws
\RuntimeException
File
- 
              core/lib/ Drupal/ Component/ Annotation/ Doctrine/ DocParser.php, line 297 
Class
- DocParser
- A parser for docblock annotations.
Namespace
Drupal\Component\Annotation\DoctrineCode
public function setImports(array $imports) {
  if ($this->namespaces) {
    throw new \RuntimeException('You must either use addNamespace(), or setImports(), but not both.');
  }
  $this->imports = $imports;
}Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.
