public function setProperties(array $props)
{
$this->properties = [];
foreach ($props as $v) {
if (!$v instanceof Property) {
throw new Nette\InvalidArgumentException('Argument must be Nette\\PhpGenerator\\Property[].');
}
$this->properties[$v->getName()] = $v;
}
return $this;
}