original_string: private function queryPDO(string $strQuery, array $aParams = [])
      {
          $oStmt = $this->oConnector->prepare($strQuery);
          if (!$oStmt->execute($aParams))
              throw new \Exception(__METHOD__ . ' - ' . $oStmt->errorInfo()[2]);
  
          list($strMethod) = explode(' ', trim($strQuery));
          switch (strtoupper($strMethod)) {
  
              case 'SELECT':
                  return $oStmt->fetchAll(\PDO::FETCH_ASSOC);
                  break;
  
              case 'INSERT':
                  return $this->oConnector->lastInsertId();
                  break;
  
              case 'UPDATE':
                  return $aParams[':id_value'];
                  break;
  
              case 'DELETE':
              default:
                  return true;
                  break;
          }
      }
code: private function queryPDO(string $strQuery, array $aParams = [])
      {
          $oStmt = $this->oConnector->prepare($strQuery);
          if (!$oStmt->execute($aParams))
              throw new \Exception(__METHOD__ . ' - ' . $oStmt->errorInfo()[2]);
  
          list($strMethod) = explode(' ', trim($strQuery));
          switch (strtoupper($strMethod)) {
  
              case 'SELECT':
                  return $oStmt->fetchAll(\PDO::FETCH_ASSOC);
                  break;
  
              case 'INSERT':
                  return $this->oConnector->lastInsertId();
                  break;
  
              case 'UPDATE':
                  return $aParams[':id_value'];
                  break;
  
              case 'DELETE':
              default:
                  return true;
                  break;
          }
      }
code_tokens: private function queryPDO ( string $ strQuery , array $ aParams = [ ] ) { $ oStmt = $ this -> oConnector -> prepare ( $ strQuery ) ; if ( ! $ oStmt -> execute ( $ aParams ) ) throw new \ Exception ( __METHOD__ . ' - ' . $ oStmt -> errorInfo ( ) [ 2 ] ) ; list ( $ strMethod ) = explode ( ' ' , trim ( $ strQuery ) ) ; switch ( strtoupper ( $ strMethod ) ) { case 'SELECT' : return $ oStmt -> fetchAll ( \ PDO :: FETCH_ASSOC ) ; break ; case 'INSERT' : return $ this -> oConnector -> lastInsertId ( ) ; break ; case 'UPDATE' : return $ aParams [ ':id_value' ] ; break ; case 'DELETE' : default : return true ; break ; } }
docstring: Execute the query with PDO and return results.
  
  @param string $strQuery SQL query.
  @param array $aParams Array of parameters to bind.
  @return array|int|bool
docstring_tokens: Execute the query with PDO and return results .