Memory

Using memory driver

This library is abandoned. Please consider using a different library.

Use this driver if you have data that doesn’t require persistence, or if you need to test your app. You can initialize this driver with predefined data.

use Opis\DataStore\Drivers\Memory;

$dataStore = new Memory([
    'settings' => [
        'language' => 'en'
    ]
]);

echo $dataStore->read("settings.language"); //> en
echo $dataStore->read("settings.currency", "$"); //> $