Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yii2
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
PSDI Army
yii2
Commits
38a19388
Commit
38a19388
authored
May 01, 2013
by
Carsten Brandt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
documentation and code style fixes
parent
fad01127
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
15 additions
and
15 deletions
+15
-15
ApcCache.php
framework/caching/ApcCache.php
+1
-1
Cache.php
framework/caching/Cache.php
+1
-1
DbCache.php
framework/caching/DbCache.php
+1
-1
DummyCache.php
framework/caching/DummyCache.php
+1
-1
FileCache.php
framework/caching/FileCache.php
+1
-1
MemCache.php
framework/caching/MemCache.php
+1
-1
RedisCache.php
framework/caching/RedisCache.php
+3
-3
WinCache.php
framework/caching/WinCache.php
+1
-1
XCache.php
framework/caching/XCache.php
+1
-1
ZendDataCache.php
framework/caching/ZendDataCache.php
+1
-1
Connection.php
framework/db/redis/Connection.php
+2
-3
CacheTest.php
tests/unit/framework/caching/CacheTest.php
+1
-0
No files found.
framework/caching/ApcCache.php
View file @
38a19388
...
...
@@ -24,7 +24,7 @@ class ApcCache extends Cache
* Retrieves a value from cache with a specified key.
* This is the implementation of the method declared in the parent class.
* @param string $key a unique key identifying the cached value
* @return string the value stored in cache, false if the value is not in the cache or expired.
* @return string
|boolean
the value stored in cache, false if the value is not in the cache or expired.
*/
protected
function
getValue
(
$key
)
{
...
...
framework/caching/Cache.php
View file @
38a19388
...
...
@@ -247,7 +247,7 @@ abstract class Cache extends Component implements \ArrayAccess
* This method should be implemented by child classes to retrieve the data
* from specific cache storage.
* @param string $key a unique key identifying the cached value
* @return string the value stored in cache, false if the value is not in the cache or expired.
* @return string
|boolean
the value stored in cache, false if the value is not in the cache or expired.
*/
abstract
protected
function
getValue
(
$key
);
...
...
framework/caching/DbCache.php
View file @
38a19388
...
...
@@ -92,7 +92,7 @@ class DbCache extends Cache
* Retrieves a value from cache with a specified key.
* This is the implementation of the method declared in the parent class.
* @param string $key a unique key identifying the cached value
* @return string the value stored in cache, false if the value is not in the cache or expired.
* @return string
|boolean
the value stored in cache, false if the value is not in the cache or expired.
*/
protected
function
getValue
(
$key
)
{
...
...
framework/caching/DummyCache.php
View file @
38a19388
...
...
@@ -24,7 +24,7 @@ class DummyCache extends Cache
* Retrieves a value from cache with a specified key.
* This is the implementation of the method declared in the parent class.
* @param string $key a unique key identifying the cached value
* @return string the value stored in cache, false if the value is not in the cache or expired.
* @return string
|boolean
the value stored in cache, false if the value is not in the cache or expired.
*/
protected
function
getValue
(
$key
)
{
...
...
framework/caching/FileCache.php
View file @
38a19388
...
...
@@ -61,7 +61,7 @@ class FileCache extends Cache
* Retrieves a value from cache with a specified key.
* This is the implementation of the method declared in the parent class.
* @param string $key a unique key identifying the cached value
* @return string the value stored in cache, false if the value is not in the cache or expired.
* @return string
|boolean
the value stored in cache, false if the value is not in the cache or expired.
*/
protected
function
getValue
(
$key
)
{
...
...
framework/caching/MemCache.php
View file @
38a19388
...
...
@@ -145,7 +145,7 @@ class MemCache extends Cache
* Retrieves a value from cache with a specified key.
* This is the implementation of the method declared in the parent class.
* @param string $key a unique key identifying the cached value
* @return string the value stored in cache, false if the value is not in the cache or expired.
* @return string
|boolean
the value stored in cache, false if the value is not in the cache or expired.
*/
protected
function
getValue
(
$key
)
{
...
...
framework/caching/RedisCache.php
View file @
38a19388
...
...
@@ -49,11 +49,11 @@ class RedisCache extends Cache
*/
public
$hostname
=
'localhost'
;
/**
* @var int the to use for connecting to the redis server. Default port is 6379.
* @var int the
port
to use for connecting to the redis server. Default port is 6379.
*/
public
$port
=
6379
;
/**
* @var string the password to use to
identify
with the redis server. If not set, no AUTH command will be sent.
* @var string the password to use to
authenticate
with the redis server. If not set, no AUTH command will be sent.
*/
public
$password
;
/**
...
...
@@ -102,7 +102,7 @@ class RedisCache extends Cache
* Retrieves a value from cache with a specified key.
* This is the implementation of the method declared in the parent class.
* @param string $key a unique key identifying the cached value
* @return string the value stored in cache, false if the value is not in the cache or expired.
* @return string
|boolean
the value stored in cache, false if the value is not in the cache or expired.
*/
protected
function
getValue
(
$key
)
{
...
...
framework/caching/WinCache.php
View file @
38a19388
...
...
@@ -24,7 +24,7 @@ class WinCache extends Cache
* Retrieves a value from cache with a specified key.
* This is the implementation of the method declared in the parent class.
* @param string $key a unique key identifying the cached value
* @return string the value stored in cache, false if the value is not in the cache or expired.
* @return string
|boolean
the value stored in cache, false if the value is not in the cache or expired.
*/
protected
function
getValue
(
$key
)
{
...
...
framework/caching/XCache.php
View file @
38a19388
...
...
@@ -25,7 +25,7 @@ class XCache extends Cache
* Retrieves a value from cache with a specified key.
* This is the implementation of the method declared in the parent class.
* @param string $key a unique key identifying the cached value
* @return string the value stored in cache, false if the value is not in the cache or expired.
* @return string
|boolean
the value stored in cache, false if the value is not in the cache or expired.
*/
protected
function
getValue
(
$key
)
{
...
...
framework/caching/ZendDataCache.php
View file @
38a19388
...
...
@@ -24,7 +24,7 @@ class ZendDataCache extends Cache
* Retrieves a value from cache with a specified key.
* This is the implementation of the method declared in the parent class.
* @param string $key a unique key identifying the cached value
* @return string the value stored in cache, false if the value is not in the cache or expired.
* @return string
|boolean
the value stored in cache, false if the value is not in the cache or expired.
*/
protected
function
getValue
(
$key
)
{
...
...
framework/db/redis/Connection.php
View file @
38a19388
...
...
@@ -379,14 +379,13 @@ class Connection extends Component
case
'-'
:
// Error reply
throw
new
Exception
(
"Redis error: "
.
$line
.
"
\n
Redis command was: "
.
$command
);
case
':'
:
// Integer reply
// no cast to int
eger
as it is in the range of a signed 64 bit integer
// no cast to int as it is in the range of a signed 64 bit integer
return
$line
;
case
'$'
:
// Bulk replies
if
(
$line
==
'-1'
)
{
return
null
;
}
$data
=
fread
(
$this
->
_socket
,
$line
+
2
);
if
(
$data
===
false
)
{
if
((
$data
=
fread
(
$this
->
_socket
,
$line
+
2
))
===
false
)
{
throw
new
Exception
(
"Failed to read from socket.
\n
Redis command was: "
.
$command
);
}
return
substr
(
$data
,
0
,
-
2
);
...
...
tests/unit/framework/caching/CacheTest.php
View file @
38a19388
...
...
@@ -117,6 +117,7 @@ abstract class CacheTest extends TestCase
$this
->
assertEquals
(
42
,
$cache
->
get
(
'number_test'
));
// should store data if it's not there yet
$this
->
assertFalse
(
$cache
->
get
(
'add_test'
));
$this
->
assertTrue
(
$cache
->
add
(
'add_test'
,
13
));
$this
->
assertEquals
(
13
,
$cache
->
get
(
'add_test'
));
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment