satwareag / php-firebird-stubs
IDE and static analysis stubs for the php-firebird extension
Requires
- php: >=8.2
Suggests
- satwareag/php-firebird: The actual php-firebird extension for runtime use
- v9.0.0
- v8.3.0
- v8.2.0
- v8.1.0
- v8.0.0
- v7.3.6-rc1
- v7.3.5
- v7.3.5-RC8
- v7.3.5-RC7
- v7.3.5-RC6
- v7.3.5-RC5
- v7.3.5-RC4
- v7.3.5-RC3
- v7.3.5-RC2
- v7.3.5-RC1
- v7.3.4
- v7.3.3
- v7.3.2
- v7.3.1
- v7.3.0
- dev-main / 7.2.x-dev
- v7.2.0
- v7.1.0
- v7.1.0-rc.1
- v7.0.0
- v7.0.0-rc.52
- v7.0.0-rc.51
- v7.0.0-rc.50
- v7.0.0-rc.49
- v7.0.0-rc.47
- v7.0.0-rc.46
- v7.0.0-rc.45
- v7.0.0-rc.44
- v7.0.0-rc.43
- v7.0.0-rc.42
- v7.0.0-rc.41
- v7.0.0-rc.40
This package is auto-updated.
Last update: 2026-03-24 08:01:52 UTC
README
IDE autocompletion and static analysis stubs for the php-firebird extension.
Installation
composer require --dev satwareag/php-firebird-stubs
Purpose
This package provides stub files that enable:
- IDE Autocompletion: Full function signatures, parameter hints, and return types for PhpStorm, VSCode (Intelephense), and other IDEs
- Static Analysis: PHPStan and Psalm support for analyzing code that uses the php-firebird extension
- Documentation: Inline PHPDoc comments describing each function and constant
What's Included
firebird-stubs.php- Constants and function declarations for allfbird_*functionsfirebird-classes.php- Extension-provided classes (Firebird\Event,Firebird\Exception)
Usage
PHPStan
The stubs are automatically loaded via Composer's autoload. If you need to reference them explicitly in your phpstan.neon:
parameters: scanFiles: - vendor/satwareag/php-firebird-stubs/firebird-stubs.php - vendor/satwareag/php-firebird-stubs/firebird-classes.php
Psalm
Add to your psalm.xml:
<stubs> <file name="vendor/satwareag/php-firebird-stubs/firebird-stubs.php"/> <file name="vendor/satwareag/php-firebird-stubs/firebird-classes.php"/> </stubs>
IDE Configuration
Most IDEs will automatically pick up the stubs via Composer autoloading. No additional configuration is typically required.
Included Functions (v7.0.0)
All fbird_* functions are stubbed, including v7.0.0 additions:
| Function | Description |
|---|---|
fbird_query_params_tx($link, $trans, $sql, ?$params) |
Explicit link + transaction + params (Doctrine DBAL) |
fbird_execute_statement($stmt) |
Execute a prepared statement resource |
fbird_execute_query($link, $sql, ...$params) |
Execute SQL with optional params |
fbird_execute_auto($link, $sql, ...$params) |
Auto-commit execution helper |
fbird_set_exception_mode(int $mode) |
Set SILENT/THROW error mode |
fbird_get_exception_mode() |
Get current error mode |
fbird_trans_start($link, array $options) |
Full TPB transaction builder |
fbird_savepoint($trans, string $name) |
Create named savepoint |
fbird_rollback_savepoint($trans, string $name) |
Rollback to savepoint |
fbird_release_savepoint($trans, string $name) |
Release savepoint |
fbird_connection_info($link) |
Connection metadata |
fbird_trans_info($trans) |
Transaction state info |
fbird_blob_seek($blob, int $offset, int $whence) |
Seekable BLOB access |
fbird_batch_create($stmt, $trans) |
Create batch (FB 4.0+) |
fbird_batch_add($batch, ...$params) |
Add row to batch |
fbird_batch_execute($batch) |
Execute batch |
fbird_batch_cancel($batch) |
Cancel batch |
fbird_escape_string(string $str) |
Escape string for SQL |
All classic fbird_connect, fbird_query, fbird_prepare, fbird_execute,
fbird_fetch_*, fbird_trans, fbird_commit, fbird_rollback, fbird_blob_*,
fbird_service_*, and event functions are also stubbed.
Version Compatibility
| Stubs Version | Extension Version | PHP Version |
|---|---|---|
| 7.0.x | 7.0.x | ≥8.1 |
Related Packages
- php-firebird - The actual C extension providing Firebird database connectivity
License
PHP License 3.01 - Same as PHP itself.
Author
satware AG - https://satware.com