/** * {@inheritdoc} */ public function addRole(RoleInterface $role) { if (!$this->hasRole($role)) { $this->roles->add($role); } return $this; }
/** * {@inheritdoc} */ public function hasChild(RoleInterface $role) { return $this->children->contains($role); }