pdo_stmt.stub.php 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. <?php
  2. /** @generate-class-entries */
  3. /** @not-serializable */
  4. class PDOStatement implements IteratorAggregate
  5. {
  6. public string $queryString;
  7. /** @tentative-return-type */
  8. public function bindColumn(string|int $column, mixed &$var, int $type = PDO::PARAM_STR, int $maxLength = 0, mixed $driverOptions = null): bool {}
  9. /** @tentative-return-type */
  10. public function bindParam(string|int $param, mixed &$var, int $type = PDO::PARAM_STR, int $maxLength = 0, mixed $driverOptions = null): bool {}
  11. /** @tentative-return-type */
  12. public function bindValue(string|int $param, mixed $value, int $type = PDO::PARAM_STR): bool {}
  13. /** @tentative-return-type */
  14. public function closeCursor(): bool {}
  15. /** @tentative-return-type */
  16. public function columnCount(): int {}
  17. /** @tentative-return-type */
  18. public function debugDumpParams(): ?bool {}
  19. /** @tentative-return-type */
  20. public function errorCode(): ?string {}
  21. /** @tentative-return-type */
  22. public function errorInfo(): array {}
  23. /** @tentative-return-type */
  24. public function execute(?array $params = null): bool {}
  25. /** @tentative-return-type */
  26. public function fetch(int $mode = PDO::FETCH_DEFAULT, int $cursorOrientation = PDO::FETCH_ORI_NEXT, int $cursorOffset = 0): mixed {}
  27. /** @tentative-return-type */
  28. public function fetchAll(int $mode = PDO::FETCH_DEFAULT, mixed ...$args): array {}
  29. /** @tentative-return-type */
  30. public function fetchColumn(int $column = 0): mixed {}
  31. /** @tentative-return-type */
  32. public function fetchObject(?string $class = "stdClass", array $constructorArgs = []): object|false {}
  33. /** @tentative-return-type */
  34. public function getAttribute(int $name): mixed {}
  35. /** @tentative-return-type */
  36. public function getColumnMeta(int $column): array|false {}
  37. /** @tentative-return-type */
  38. public function nextRowset(): bool {}
  39. /** @tentative-return-type */
  40. public function rowCount(): int {}
  41. /** @tentative-return-type */
  42. public function setAttribute(int $attribute, mixed $value): bool {}
  43. /** @return bool */
  44. public function setFetchMode(int $mode, mixed ...$args) {} // TODO make return type void
  45. public function getIterator(): Iterator {}
  46. }
  47. /** @not-serializable */
  48. final class PDORow
  49. {
  50. public string $queryString;
  51. }