Doctrine\Common\Cache\SQLite3Cache::__construct PHP Method

__construct() public method

Calling the constructor will ensure that the database file and table exist and will create both if they don't.
public __construct ( SQLite3 $sqlite, string $table )
$sqlite SQLite3
$table string
    public function __construct(SQLite3 $sqlite, $table)
    {
        $this->sqlite = $sqlite;
        $this->table = (string) $table;
        list($id, $data, $exp) = $this->getFields();
        return $this->sqlite->exec(sprintf('CREATE TABLE IF NOT EXISTS %s(%s TEXT PRIMARY KEY NOT NULL, %s BLOB, %s INTEGER)', $table, $id, $data, $exp));
    }