src/Alchemy/Component/Cerberus/Model/Base/Role.php
public function addRolePermission(ChildRolePermission $l)
    {
        if ($this->collRolePermissions === null) {
            $this->initRolePermissions();
            $this->collRolePermissionsPartial = true;
        }

        if (!$this->collRolePermissions->contains($l)) {
            $this->doAddRolePermission($l);
        }

        return $this;
    }
public function addRolePermission(ChildRolePermission $l)
    {
        if ($this->collRolePermissions === null) {
            $this->initRolePermissions();
            $this->collRolePermissionsPartial = true;
        }

        if (!$this->collRolePermissions->contains($l)) {
            $this->doAddRolePermission($l);
        }

        return $this;
    }
public function addRolePermission ( ChildRolePermission $ l ) { if ( $ this -> collRolePermissions === null ) { $ this -> initRolePermissions ( ) ; $ this -> collRolePermissionsPartial = true ; } if ( ! $ this -> collRolePermissions -> contains ( $ l ) ) { $ this -> doAddRolePermission ( $ l ) ; } return $ this ; }
Method called to associate a ChildRolePermission object to this object
through the ChildRolePermission foreign key attribute.

@param  ChildRolePermission $l ChildRolePermission
@return $this|\Alchemy\Component\Cerberus\Model\Role The current object (for fluent API support)
Method called to associate a ChildRolePermission object to this object through the ChildRolePermission foreign key attribute .