Download the PHP package daycry/doctrine without Composer
On this page you can find all versions of the php package daycry/doctrine. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download daycry/doctrine
More information about daycry/doctrine
Files in daycry/doctrine
Package doctrine
Short Description Standalone Doctrine ORM toolkit with an optional CodeIgniter 4 adapter
License MIT
Homepage https://github.com/daycry/doctrine
Informations about the package doctrine
Doctrine ORM Toolkit for PHP and CodeIgniter 4
Standalone Doctrine ORM toolkit for PHP 8.5, with an optional CodeIgniter 4 adapter.
📖 Documentation: https://daycry.github.io/doctrine/
Packages and release status
This documentation describes version 6.0, with breaking API and namespace changes. See the migration guide before upgrading. Published package badges can refer to an earlier release.
| Package | Role |
|---|---|
daycry/doctrine |
Standalone core: ORM configuration, DataTables, PSR-6 caching, PSR-3 logging, named managers and console tools |
daycry/doctrine-codeigniter4 |
Optional adapter: CI4 configuration/services, database groups, cache backends, helpers, toolbar and Spark |
The core has no CodeIgniter runtime dependency. Both packages require PHP ^8.5; the core uses ORM ^3.7, DBAL ^4.5, Symfony Cache/Console ^8 and DoctrineExtensions ^1.5. The adapter also requires CI4 ^4.7.
Installation
Choose one package from Packagist:
Local path repositories are also available for development.
Standalone quick start
For mapped entities, assign existing directories to $config->entities before
constructing Doctrine. Native lazy objects are always enabled; no proxy files are
generated. See standalone usage for persistent cache pools,
logging, named managers and lifecycle handling.
CodeIgniter quick start
The publisher writes app/Config/Doctrine.php and cli-config.php. The config
extends Daycry\Doctrine\CodeIgniter4\Config\Doctrine and contains application
overrides. Configure connections through Config\Database and caches through
Config\Cache.
See CI4 usage for shared services, helpers and group resets, and debug toolbar for collector/filter registration.
DataTables
The Builder works in either package and accepts an ORM QueryBuilder and a request array. It does not require an HTTP framework:
The query must use the p alias in this example. The response contains draw,
recordsTotal, recordsFiltered and data. The default page cap is 200;
length=-1 is clamped to it, and the cap must remain positive.
Use getPage() for a WindowPage with items and filtered total.
See search operators.
Caching, logging and extension points
- Inject
CachePoolsinto the core for query/result/metadata/SLC storage; defaults are independent process-local ArrayAdapters. The CI4 adapter creates pools from its framework backend. - Use
Cache\CacheAsidedirectly in standalone code. The adapter also autoloads the namespacedDaycry\Doctrine\CodeIgniter4\Helpers\getFromCacheOrQueryfunction. - Enable SLC, statistics, custom DBAL types, SQL filters, event listeners/subscribers, DBAL middlewares and a default repository through configuration.
- Query logging accepts a PSR-3 logger and a slow-query threshold. The core requires an injected logger; the adapter resolves CI4's logger service.
See SLC configuration and cache statistics.
Console
The standalone console loads an application bootstrap returning Doctrine or a ManagerRegistry. Spark commands use the CI4 adapter:
Doctor and warmup do not change the schema. They report connection/mapping/cache failures through nonzero exit codes. The console guide explains the bootstrap, named managers and native ORM commands.
Development
The integration suite needs its configured test database and optional cache services. The native core suite uses SQLite and a separate bootstrap. CI also installs isolated consumers to verify the core without CI4 installed and the adapter's framework discovery. See validation records.
Documentation
- Installation
- Standalone core
- Configuration
- CI4 services and helpers
- DataTables
- Console commands
- 6.x migration
- Changelog
License
MIT.
All versions of doctrine with dependencies
beberlei/doctrineextensions Version ^1.5
doctrine/dbal Version ^4.5
doctrine/orm Version ^3.7
scienta/doctrine-json-functions Version ^6.5
symfony/cache Version ^8
symfony/console Version ^8
psr/cache Version ^3
psr/log Version ^3
doctrine/event-manager Version ^2