Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Tests with 4 cache engines, 2 additional cache classes to support obj…
…ect saving (added serialization)
- Loading branch information
Showing
9 changed files
with
293 additions
and
167 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 |
---|---|---|
@@ -1 +1,4 @@ | ||
*.tgz | ||
test/temp/file | ||
!.gitignore | ||
|
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,22 @@ | ||
<?php | ||
|
||
class sfFileTaggingCache extends sfFileCache | ||
{ | ||
/** | ||
* @see sfCache | ||
*/ | ||
public function get($key, $default = null) | ||
{ | ||
$data = parent::get($key, $default); | ||
|
||
return null === $data ? $default : unserialize($data); | ||
} | ||
|
||
/** | ||
* @see sfCache | ||
*/ | ||
public function set($key, $data, $lifetime = null) | ||
{ | ||
return parent::set($key, serialize($data), $lifetime); | ||
} | ||
} |
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,22 @@ | ||
<?php | ||
|
||
class sfSQLiteTaggingCache extends sfSQLiteCache | ||
{ | ||
/** | ||
* @see sfCache | ||
*/ | ||
public function get($key, $default = null) | ||
{ | ||
$data = parent::get($key, $default); | ||
|
||
return null === $data ? $default : unserialize($data); | ||
} | ||
|
||
/** | ||
* @see sfCache | ||
*/ | ||
public function set($key, $data, $lifetime = null) | ||
{ | ||
return parent::set($key, serialize($data), $lifetime); | ||
} | ||
} |
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
Oops, something went wrong.