- Added caching mechanism as an event listener
This commit is contained in:
1 parent
b601939459
commit
9eed2fe1a8
25 files changed
+607
-402
No files matched your search
@@ -2,26 +2,23 @@
|
||||
|
||||
namespace Ulmus;
|
||||
|
||||
use Psr\SimpleCache\CacheInterface;
|
||||
use Ulmus\Adapter\AdapterInterface;
|
||||
|
||||
use Ulmus\Common\PdoObject;
|
||||
|
||||
class ConnectionAdapter
|
||||
{
|
||||
public string $name;
|
||||
|
||||
public array $configuration;
|
||||
|
||||
protected AdapterInterface $adapter;
|
||||
|
||||
protected PdoObject $pdo;
|
||||
|
||||
public function __construct(string $name = "default", array $configuration = [], bool $default = false)
|
||||
{
|
||||
$this->name = $name;
|
||||
|
||||
$this->configuration = $configuration;
|
||||
|
||||
public function __construct(
|
||||
public string $name = "default",
|
||||
protected array $configuration = [],
|
||||
public bool $default = false,
|
||||
public ? CacheInterface $cacheObject = null
|
||||
) {
|
||||
Ulmus::registerAdapter($this, $default);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user