jmflava/mongo-morph
Composer 安装命令:
composer require jmflava/mongo-morph
包简介
A PHP object that can flatten MongoDB data or restore flattened data to MongoDb format.
README 文档
README
MongoMorph is a PHP object that can flatten MongoDB data or restore flattened data to MongoDb format. You may find it useful if you want to interface with your Mongo database via flat files.
Implementation Example
The most typical use case of MongoMorph is to use it within a command, which could look like the following:
// Code to spin up a new Mongo connection...
$db = $mongo->selectDb('your-db-here');
$mongoMorph = new Jmflava\MongoMorph\MongoMorph($db, __DIR__ . '/path/to/morph/dir');
if ($argv[1] === 'backup') {
$mongoMorph->backup();
} elseif ($argv[1] === 'restore') {
$mongoMorph->restore();
}
统计信息
- 总下载量: 26
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: Unknown
- 更新时间: 2013-03-28