src/Searsaw/Drawbridge/models/BridgeUser.php
public function checkRole($check, BridgeRole $has)
    {
        if (is_string($check))
            return $this->checkRoleByName($check, $has);
        elseif (is_numeric($check))
            return $this->checkRoleById($check, $has);
        elseif ($check instanceof BridgeRole)
            return $this->checkRoleByObject($check, $has);
        else
            throw new \InvalidArgumentException('Role to check must be a name, ID, or Role object.');
    }
public function checkRole($check, BridgeRole $has)
    {
        if (is_string($check))
            return $this->checkRoleByName($check, $has);
        elseif (is_numeric($check))
            return $this->checkRoleById($check, $has);
        elseif ($check instanceof BridgeRole)
            return $this->checkRoleByObject($check, $has);
        else
            throw new \InvalidArgumentException('Role to check must be a name, ID, or Role object.');
    }
public function checkRole ( $ check , BridgeRole $ has ) { if ( is_string ( $ check ) ) return $ this -> checkRoleByName ( $ check , $ has ) ; elseif ( is_numeric ( $ check ) ) return $ this -> checkRoleById ( $ check , $ has ) ; elseif ( $ check instanceof BridgeRole ) return $ this -> checkRoleByObject ( $ check , $ has ) ; else throw new \ InvalidArgumentException ( 'Role to check must be a name, ID, or Role object.' ) ; }
Checks to see if a given role is equal to a role the user already has

@param $check string|integer|\Searsaw\Drawbridge\Models\BridgeRole The role to check
@param $has   \Searsaw\Drawbridge\Models\BridgeRole The role the user has to check against

@return mixed
@throws \InvalidArgumentException
Checks to see if a given role is equal to a role the user already has