forked from php-fig/fig-standards
-
-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added main interfaces to their own files
This will allow people to actually use the interfaces.
- Loading branch information
Showing
2 changed files
with
42 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
|
||
namespace PSR\Cache; | ||
|
||
interface CacheFactory | ||
{ | ||
/** | ||
* | ||
ÊÊÊ * @param string $key | ||
ÊÊÊ * @return CacheItem | ||
*/ | ||
function getCache($key); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
namespace PSR\Cache; | ||
|
||
interface CacheItem | ||
{ | ||
/** | ||
* | ||
* @return mixed | ||
*/ÊÊÊÊÊÊÊ | ||
function get(); | ||
|
||
/** | ||
* | ||
* @param mixed $value | ||
* @param int $ttl | ||
* @return bool | ||
*/ ÊÊÊÊÊÊÊ | ||
function set($value, $ttl = null); | ||
|
||
/** | ||
* | ||
* @return bool | ||
*/ | ||
function isMiss(); | ||
|
||
/** | ||
* | ||
* @return mixed | ||
*/ | ||
function clear(); | ||
} |