Simple key-value SQLite storage

Simple key-value SQLite storage

README

packagist php-v travis codacy license

Pairs implements a simple key-value SQLite storage.

  • Easy to use
  • Built-in cache

Usage

$pairs = new Pairs( __DIR__ . '/storage.sqlite', 'pairs', true );

$key = 1;
$value = 'Hello, World!';
$pairs->setKeyValue( $key, $value );

if( $pairs->getKey( $value ) !== $key ||
    $pairs->getValue( $key ) !== $value )
    exit( 1 );

Requirements

Installation

Require through Composer:

{
    "require": {
        "deemru/pairs": "1.0.*"
    }
}

Source

Add a Comment

Tu dirección de correo electrónico no será publicada. Los campos obligatorios están marcados con *