承接 wikimedia/cdb 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

wikimedia/cdb

最新稳定版本:3.0.0

Composer 安装命令:

composer require wikimedia/cdb

包简介

Constant Database (CDB) wrapper library for PHP. Provides pure-PHP fallback when dba_* functions are absent.

README 文档

README

Latest Stable Version License

CDB functions for PHP

CDB, short for "constant database", refers to a very fast and highly reliable database system which uses a simple file with key value pairs. This library wraps the CDB functionality exposed in PHP via the dba_* functions. In cases where dba_* functions are not present or are not compiled with CDB support, a pure-PHP implementation is provided for falling back.

Additional documentation about the library can be found on mediawiki.org.

Usage

// Reading a CDB file
$cdb = Cdb\Reader::open( 'db.cdb' );
$foo = $cdb->get( 'somekey' );

// Writing to a CDB file
$cdb = Cdb\Writer::open( 'anotherdb.cdb' );
$cdb->set( 'somekey', $foo );
// Using the CLI
$ cdb ./myfile.cdb [get|list|match] <parameter>

Running tests

composer install --prefer-dist
composer test

History

This library was first introduced in MediaWiki 1.16 (r52203). It was split out of the MediaWiki codebase and published as an independent library during the MediaWiki 1.25 development cycle.

统计信息

  • 总下载量: 974.17k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 14
  • 点击次数: 1
  • 依赖项目数: 4
  • 推荐数: 0

GitHub 信息

  • Stars: 14
  • Watchers: 13
  • Forks: 8
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-2.0-or-later
  • 更新时间: 2014-12-08