src/Searsaw/Drawbridge/models/BridgeRole.php
public function addSinglePermission($permission)
    {
        if (is_string($permission))
            return $this->addPermissionByName($permission);
        elseif (is_numeric($permission))
            return $this->addPermissionById($permission);
        elseif ($permission instanceof BridgePermission)
            return $this->addPermissionByObject($permission);
        else
            throw new \InvalidArgumentException('Permission must be a name, ID, or Permission object.');
    }
public function addSinglePermission($permission)
    {
        if (is_string($permission))
            return $this->addPermissionByName($permission);
        elseif (is_numeric($permission))
            return $this->addPermissionById($permission);
        elseif ($permission instanceof BridgePermission)
            return $this->addPermissionByObject($permission);
        else
            throw new \InvalidArgumentException('Permission must be a name, ID, or Permission object.');
    }
public function addSinglePermission ( $ permission ) { if ( is_string ( $ permission ) ) return $ this -> addPermissionByName ( $ permission ) ; elseif ( is_numeric ( $ permission ) ) return $ this -> addPermissionById ( $ permission ) ; elseif ( $ permission instanceof BridgePermission ) return $ this -> addPermissionByObject ( $ permission ) ; else throw new \ InvalidArgumentException ( 'Permission must be a name, ID, or Permission object.' ) ; }
Add a single permission. The argument is a string, integer, or instance of BridgePermission

@param $permission string|integer|\Searsaw\Drawbridge\Models\BridgePermission

@throws \InvalidArgumentException

@return \Searsaw\Drawbridge\Models\BridgePermission
Add a single permission . The argument is a string integer or instance of BridgePermission