PHP code example of sokil / php-2q

1. Go to this page and download the library: Download sokil/php-2q library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

sokil / php-2q example snippets




$cache = new TwoQCache(
    inQueueCapacity: 2,
    outQueueCapacity: 4,
    mainQueueCapacity: 2
);

$cache->set('key', 'value');
$cache->get('key');

composer req sokil/php-2q