earc/data-filesystem
Composer 安装命令:
composer require earc/data-filesystem
包简介
eArc - the explicit architecture framework - data filesystem component
README 文档
README
Filesystem bridge providing a basic entity database/value-store/backup-system for the earc/data abstraction.
installation
Install the earc/data-filesystem library via composer.
$ composer require earc/data-filesystem
basic usage
Initialize the earc/data abstraction in your index.php, bootstrap or configuration script.
use eArc\Data\Initializer; Initializer::init();
Then register the earc/data-filesystem bridge to the earc/data onLoad,
onPersit, onRemove and onFind events and set the data path for your filesystem.
use eArc\Data\ParameterInterface; use eArc\DataFilesystem\FilesystemDataBridge; di_tag(ParameterInterface::TAG_ON_LOAD, FilesystemDataBridge::class); di_tag(ParameterInterface::TAG_ON_PERSIST, FilesystemDataBridge::class); di_tag(ParameterInterface::TAG_ON_REMOVE, FilesystemDataBridge::class); di_tag(ParameterInterface::TAG_ON_FIND, FilesystemDataBridge::class); di_set_param(\eArc\DataFilesystem\ParameterInterface::DATA_PATH, '/path/to/save/the/entity/data');
Hint: The first ParameterInterface belongs to earc/data library the second to
earc/data-filesystem bridge.
Now earc/data uses your filesystem to save the data of your entities.
releases
release 0.0
- the first official release
- PHP ^8.0
统计信息
- 总下载量: 29
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 2
- 依赖项目数: 3
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2021-04-03