original_string: public function canAs(Authorizable $user, string $action): bool
      {
          $this->setUser($user);
  
          $permission = $this->can($action);
  
          $this->revokeUser();
  
          return $permission;
      }
code: public function canAs(Authorizable $user, string $action): bool
      {
          $this->setUser($user);
  
          $permission = $this->can($action);
  
          $this->revokeUser();
  
          return $permission;
      }
code_tokens: public function canAs ( Authorizable $ user , string $ action ) : bool { $ this -> setUser ( $ user ) ; $ permission = $ this -> can ( $ action ) ; $ this -> revokeUser ( ) ; return $ permission ; }
docstring: Verify whether current user has sufficient roles to access the
  actions based on available type of access.
  
  @param  \Orchestra\Contracts\Authorization\Authorizable  $user
  @param  string  $action     A string of action name
  
  @throws \InvalidArgumentException
  
  @return bool
docstring_tokens: Verify whether current user has sufficient roles to access the actions based on available type of access .