Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'hotfix/2808'

Close #2808
  • Loading branch information...
commit e3342c52ac547994e5979a774edd4ae919fb3dbc 2 parents 01d5253 + 45e6a57
@weierophinney weierophinney authored
Showing with 15 additions and 15 deletions.
  1. +15 −15 library/Zend/Serializer/Serializer.php
View
30 library/Zend/Serializer/Serializer.php
@@ -45,7 +45,7 @@ public static function factory($adapterName, $adapterOptions = null)
return $adapterName; // $adapterName is already an adapter object
}
- return self::getAdapterPluginManager()->get($adapterName, $adapterOptions);
+ return static::getAdapterPluginManager()->get($adapterName, $adapterOptions);
}
/**
@@ -56,7 +56,7 @@ public static function factory($adapterName, $adapterOptions = null)
*/
public static function setAdapterPluginManager(AdapterPluginManager $adapters)
{
- self::$adapters = $adapters;
+ static::$adapters = $adapters;
}
/**
@@ -66,10 +66,10 @@ public static function setAdapterPluginManager(AdapterPluginManager $adapters)
*/
public static function getAdapterPluginManager()
{
- if (self::$adapters === null) {
- self::$adapters = new AdapterPluginManager();
+ if (static::$adapters === null) {
+ static::$adapters = new AdapterPluginManager();
}
- return self::$adapters;
+ return static::$adapters;
}
/**
@@ -79,8 +79,8 @@ public static function getAdapterPluginManager()
*/
public static function resetAdapterPluginManager()
{
- self::$adapters = new AdapterPluginManager();
- return self::$adapters;
+ static::$adapters = new AdapterPluginManager();
+ return static::$adapters;
}
/**
@@ -91,7 +91,7 @@ public static function resetAdapterPluginManager()
*/
public static function setDefaultAdapter($adapter, $adapterOptions = null)
{
- self::$defaultAdapter = self::factory($adapter, $adapterOptions);
+ static::$defaultAdapter = static::factory($adapter, $adapterOptions);
}
/**
@@ -101,10 +101,10 @@ public static function setDefaultAdapter($adapter, $adapterOptions = null)
*/
public static function getDefaultAdapter()
{
- if (!self::$defaultAdapter instanceof Adapter) {
- self::setDefaultAdapter(self::$defaultAdapter);
+ if (!static::$defaultAdapter instanceof Adapter) {
+ static::setDefaultAdapter(static::$defaultAdapter);
}
- return self::$defaultAdapter;
+ return static::$defaultAdapter;
}
/**
@@ -120,9 +120,9 @@ public static function getDefaultAdapter()
public static function serialize($value, $adapter = null, $adapterOptions = null)
{
if ($adapter !== null) {
- $adapter = self::factory($adapter, $adapterOptions);
+ $adapter = static::factory($adapter, $adapterOptions);
} else {
- $adapter = self::getDefaultAdapter();
+ $adapter = static::getDefaultAdapter();
}
return $adapter->serialize($value);
@@ -141,9 +141,9 @@ public static function serialize($value, $adapter = null, $adapterOptions = null
public static function unserialize($serialized, $adapter = null, $adapterOptions = null)
{
if ($adapter !== null) {
- $adapter = self::factory($adapter, $adapterOptions);
+ $adapter = static::factory($adapter, $adapterOptions);
} else {
- $adapter = self::getDefaultAdapter();
+ $adapter = static::getDefaultAdapter();
}
return $adapter->unserialize($serialized);
Please sign in to comment.
Something went wrong with that request. Please try again.