@@ 49-58 (lines=10) @@ | ||
46 | /** |
|
47 | * @inheritdoc |
|
48 | */ |
|
49 | public function set($key, $expiresAt) |
|
50 | { |
|
51 | $connection = $this->_em->getConnection(); |
|
52 | $statement = $connection->exec( |
|
53 | 'INSERT INTO nv_request_limit_items (item_key, expires_at) VALUES item_key = :item_key, expires_at = :expires_at' |
|
54 | ); |
|
55 | $statement->bindParam('item_key', $key); |
|
56 | $statement->bindParam('expires_at', $key); |
|
57 | $connection->close(); |
|
58 | } |
|
59 | ||
60 | /** |
|
61 | * @inheritdoc |
|
@@ 63-71 (lines=9) @@ | ||
60 | /** |
|
61 | * @inheritdoc |
|
62 | */ |
|
63 | public function remove($key) |
|
64 | { |
|
65 | $connection = $this->_em->getConnection(); |
|
66 | $statement = $connection->exec('DELETE FROM nv_request_limit_items WHERE item_key = :item_key'); |
|
67 | $statement->bindParam('item_key', $key); |
|
68 | $connection->close(); |
|
69 | } |
|
70 | ||
71 | /** |
|
72 | * @return array |
|
73 | */ |
|
74 | public function fetchAllItems() |