forked from bankiru/doctrine-api-client
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathEntityDataCacheInterface.php
More file actions
47 lines (40 loc) · 985 Bytes
/
EntityDataCacheInterface.php
File metadata and controls
47 lines (40 loc) · 985 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<?php
namespace Bankiru\Api\Doctrine;
use Bankiru\Api\Doctrine\Cache\CacheConfigurationInterface;
use Bankiru\Api\Doctrine\Mapping\ApiMetadata;
interface EntityDataCacheInterface
{
/**
* Returns cached entity source data
*
* @param array $identifier
*
* @return mixed|null Entity source data or NULL if no data cached
*/
public function get(array $identifier);
/**
* Stores entity source data to cache
*
* @param mixed $data Entity source data
* @param array $identifier
*
* @return void
*/
public function set(array $identifier, $data);
/**
* Clears the cache for given entity identifier
*
* @param array $identifier
*
* @return void
*/
public function clear(array $identifier);
/**
* @return ApiMetadata
*/
public function getMetadata();
/**
* @return CacheConfigurationInterface
*/
public function getConfiguration();
}