maileryio / cycle-mapper
Mapper for Cycle ORM
Installs: 384
Dependents: 0
Suggesters: 0
Security: 0
Stars: 2
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/maileryio/cycle-mapper
Requires
- php: ^7.4
- doctrine/collections: ^1.6
- foxy/foxy: ^1.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^2.16
- phan/phan: ^2.4
- phpunit/phpunit: ^9.0
This package is auto-updated.
Last update: 2025-09-21 05:08:12 UTC
README
Mapper for Cycle ORM
Mapper for Cycle ORM
Installation
The preferred way to install this library is through composer.
Either run
php composer.phar require "maileryio/cycle-mapper"
or add
"maileryio/cycle-mapper": "*"
to the require section of your composer.json.
Usage
/** * @Cycle\Annotated\Annotation\Table( * columns = { * "created_at": @Cycle\Annotated\Annotation\Column(type = "datetime"), * "updated_at": @Cycle\Annotated\Annotation\Column(type = "datetime") * } * ) */ class SubscriberMapper extends ChainedMapper { /** * {@inheritdoc} */ protected function getChainItemList(): ChainItemList { return new ChainItemList([ (new Timestamped()) ->withCreatedAt('created_at') ->withUpdatedAt('updated_at'), ]); } }
License
This project is released under the terms of the BSD-3-Clause license. Read more here.
Copyright © 2020, Mailery (https://mailery.io)