simondevelop / doff
PHP 库,通过查询函数管理 yaml 表格数据
0.2.0
2021-08-05 16:04 UTC
Requires
- php: >=7.3
- simondevelop/array-organize: ^0.2
- symfony/yaml: ^5.3
Requires (Dev)
- phpstan/phpstan: ^0.12.94
- phpunit/phpunit: ^9.5.8
- squizlabs/php_codesniffer: 4.0.x-dev
This package is auto-updated.
Last update: 2024-08-29 12:11:30 UTC
README
doff
DOFF for Data Oriented Flat-File,通过查询函数管理 yaml 表格数据的库。
composer require simondevelop/doff
示例
<?php // Initiate doff require "vendor/autoload.php"; use SimonDevelop\Doff; $settings = [ "path" => "/path/of/data/files/", "chmod" => 0770 // optionnal, octal value (only string or integer type) ]; $doff = new Doff($settings);
在您的 /path/of/data/files
# test.yml - name: 'test 0' - name: 'test 1' - name: 'test 2' - name: '3' - name: '4'
<?php //... // Example with like query for query.yml $datas = $doff->select("query", ["name" => "%test%"]); $datas = [ ["name" => "test 0"], ["name" => "test 1"], ["name" => "test 2"] ];
查看更多 文档
前往贡献!
- 查看 行为准则
- 查看 贡献文件
- 查看 Pull Request 模板