original_string: public static function executeSingleton0(string $query)
    {
      $result = self::query($query);
      $row    = $result->fetch_array(MYSQLI_NUM);
      $n      = $result->num_rows;
      $result->free();
  
      if (self::$mysqli->more_results()) self::$mysqli->next_result();
  
      if (!($n==0 || $n==1))
      {
        throw new ResultException('0 or 1', $n, $query);
      }
  
      return $row[0];
    }
code: public static function executeSingleton0(string $query)
    {
      $result = self::query($query);
      $row    = $result->fetch_array(MYSQLI_NUM);
      $n      = $result->num_rows;
      $result->free();
  
      if (self::$mysqli->more_results()) self::$mysqli->next_result();
  
      if (!($n==0 || $n==1))
      {
        throw new ResultException('0 or 1', $n, $query);
      }
  
      return $row[0];
    }
code_tokens: public static function executeSingleton0 ( string $ query ) { $ result = self :: query ( $ query ) ; $ row = $ result -> fetch_array ( MYSQLI_NUM ) ; $ n = $ result -> num_rows ; $ result -> free ( ) ; if ( self :: $ mysqli -> more_results ( ) ) self :: $ mysqli -> next_result ( ) ; if ( ! ( $ n == 0 || $ n == 1 ) ) { throw new ResultException ( '0 or 1' , $ n , $ query ) ; } return $ row [ 0 ] ; }
docstring: Executes a query that returns 0 or 1 row with one column.
  Throws an exception if the query selects 2 or more rows.
  
  @param string $query The SQL statement.
  
  @return mixed The selected value.
  
  @since 1.0.0
  @api
docstring_tokens: Executes a query that returns 0 or 1 row with one column . Throws an exception if the query selects 2 or more rows .