19 lines
345 B
PHP
19 lines
345 B
PHP
|
<?php
|
||
|
namespace Incoviba\Service;
|
||
|
|
||
|
use Predis\Client;
|
||
|
|
||
|
class Redis
|
||
|
{
|
||
|
public function __construct(protected Client $client) {}
|
||
|
|
||
|
public function get(string $name): mixed
|
||
|
{
|
||
|
return $this->client->get($name);
|
||
|
}
|
||
|
public function set(string $name, mixed $value): void
|
||
|
{
|
||
|
$this->client->set($name, $value);
|
||
|
}
|
||
|
}
|