From 40c27dd855acea6b40dd06b94cbc3a40e4c10fed Mon Sep 17 00:00:00 2001 From: Michel Hunziker Date: Mon, 7 Apr 2014 11:00:52 +0200 Subject: [PATCH 1/3] Fix undefined classes in phpDoc --- library/Zend/Barcode/Object/Identcode.php | 2 +- library/Zend/Cache/Storage/Adapter/Filesystem.php | 2 +- library/Zend/Cache/Storage/Adapter/MemcacheOptions.php | 2 +- .../Zend/Cache/Storage/Adapter/MemcacheResourceManager.php | 1 + library/Zend/Cache/Storage/Adapter/Redis.php | 1 + library/Zend/Code/Reflection/FileReflection.php | 2 +- .../Zend/Db/Adapter/Driver/Pdo/Feature/OracleRowCounter.php | 2 +- .../Zend/Db/Adapter/Driver/Pdo/Feature/SqliteRowCounter.php | 2 +- library/Zend/Db/TableGateway/AbstractTableGateway.php | 2 +- library/Zend/Di/Di.php | 2 +- library/Zend/Dom/DOMXPath.php | 2 +- library/Zend/Dom/Query.php | 2 +- library/Zend/Feed/Reader/Reader.php | 2 +- library/Zend/Feed/Writer/ExtensionManager.php | 2 +- library/Zend/Filter/DateTimeFormatter.php | 2 +- library/Zend/Filter/FilterChain.php | 3 ++- library/Zend/Filter/Inflector.php | 2 +- library/Zend/Form/FormElementManager.php | 3 ++- library/Zend/Form/InputFilterProviderFieldset.php | 1 + library/Zend/Form/LabelAwareInterface.php | 2 +- library/Zend/Http/Headers.php | 2 +- library/Zend/Log/Writer/AbstractWriter.php | 1 - library/Zend/Mail/Storage/Writable/Maildir.php | 2 +- library/Zend/Mime/Part.php | 2 +- library/Zend/ModuleManager/ModuleManager.php | 2 +- library/Zend/Mvc/I18n/Translator.php | 4 ++-- .../Zend/Mvc/Router/Http/TranslatorAwareTreeRouteStack.php | 1 + library/Zend/Navigation/Page/AbstractPage.php | 2 +- library/Zend/Navigation/Page/Uri.php | 2 +- .../Zend/Permissions/Acl/Assertion/AssertionAggregate.php | 2 +- library/Zend/Session/SaveHandler/MongoDB.php | 2 +- library/Zend/Session/Service/StorageFactory.php | 2 +- library/Zend/Soap/Server.php | 6 +++--- library/Zend/Stdlib/PriorityList.php | 2 +- .../Test/PHPUnit/Controller/AbstractControllerTestCase.php | 2 +- .../Helper/Placeholder/Container/AbstractStandalone.php | 2 +- 36 files changed, 40 insertions(+), 35 deletions(-) diff --git a/library/Zend/Barcode/Object/Identcode.php b/library/Zend/Barcode/Object/Identcode.php index 14d50e6d59b..a2b7fd355ed 100644 --- a/library/Zend/Barcode/Object/Identcode.php +++ b/library/Zend/Barcode/Object/Identcode.php @@ -40,7 +40,7 @@ public function getTextToDisplay() * Check allowed characters * @param string $value * @return string - * @throws Exception + * @throws Exception\BarcodeValidationException */ public function validateText($value) { diff --git a/library/Zend/Cache/Storage/Adapter/Filesystem.php b/library/Zend/Cache/Storage/Adapter/Filesystem.php index aee3f835ce0..cbe2899aeca 100644 --- a/library/Zend/Cache/Storage/Adapter/Filesystem.php +++ b/library/Zend/Cache/Storage/Adapter/Filesystem.php @@ -1599,7 +1599,7 @@ protected function putFileContent($file, $data, $nonBlocking = false, & $wouldbl * * @param string $file * @return void - * @throws RuntimeException + * @throws Exception\RuntimeException */ protected function unlink($file) { diff --git a/library/Zend/Cache/Storage/Adapter/MemcacheOptions.php b/library/Zend/Cache/Storage/Adapter/MemcacheOptions.php index 5fa37d77944..5fcdc3427b3 100644 --- a/library/Zend/Cache/Storage/Adapter/MemcacheOptions.php +++ b/library/Zend/Cache/Storage/Adapter/MemcacheOptions.php @@ -197,7 +197,7 @@ public function getServers() /** * Set compress threshold * - * @param int|string|array|ArrayAccess|null $threshold + * @param int|string|array|\ArrayAccess|null $threshold * @return MemcacheOptions */ public function setAutoCompressThreshold($threshold) diff --git a/library/Zend/Cache/Storage/Adapter/MemcacheResourceManager.php b/library/Zend/Cache/Storage/Adapter/MemcacheResourceManager.php index e8a266b6893..6c46236e6e2 100644 --- a/library/Zend/Cache/Storage/Adapter/MemcacheResourceManager.php +++ b/library/Zend/Cache/Storage/Adapter/MemcacheResourceManager.php @@ -9,6 +9,7 @@ namespace Zend\Cache\Storage\Adapter; +use ArrayAccess; use Memcache as MemcacheResource; use Traversable; use Zend\Cache\Exception; diff --git a/library/Zend/Cache/Storage/Adapter/Redis.php b/library/Zend/Cache/Storage/Adapter/Redis.php index 2ce9062c43b..bd6f9fe123f 100644 --- a/library/Zend/Cache/Storage/Adapter/Redis.php +++ b/library/Zend/Cache/Storage/Adapter/Redis.php @@ -12,6 +12,7 @@ use Redis as RedisResource; use RedisException as RedisResourceException; use stdClass; +use Traversable; use Zend\Cache\Exception; use Zend\Cache\Storage\Capabilities; use Zend\Cache\Storage\FlushableInterface; diff --git a/library/Zend/Code/Reflection/FileReflection.php b/library/Zend/Code/Reflection/FileReflection.php index d48ab943261..dfd07a0464e 100644 --- a/library/Zend/Code/Reflection/FileReflection.php +++ b/library/Zend/Code/Reflection/FileReflection.php @@ -49,7 +49,7 @@ class FileReflection implements ReflectionInterface protected $requiredFiles = array(); /** - * @var ReflectionClass[] + * @var ClassReflection[] */ protected $classes = array(); diff --git a/library/Zend/Db/Adapter/Driver/Pdo/Feature/OracleRowCounter.php b/library/Zend/Db/Adapter/Driver/Pdo/Feature/OracleRowCounter.php index 1a9fad34299..2412e3af67d 100644 --- a/library/Zend/Db/Adapter/Driver/Pdo/Feature/OracleRowCounter.php +++ b/library/Zend/Db/Adapter/Driver/Pdo/Feature/OracleRowCounter.php @@ -64,7 +64,7 @@ public function getCountForSql($sql) /** * @param $context - * @return closure + * @return \Closure */ public function getRowCountClosure($context) { diff --git a/library/Zend/Db/Adapter/Driver/Pdo/Feature/SqliteRowCounter.php b/library/Zend/Db/Adapter/Driver/Pdo/Feature/SqliteRowCounter.php index b5807a2809b..a78132ea5c2 100644 --- a/library/Zend/Db/Adapter/Driver/Pdo/Feature/SqliteRowCounter.php +++ b/library/Zend/Db/Adapter/Driver/Pdo/Feature/SqliteRowCounter.php @@ -64,7 +64,7 @@ public function getCountForSql($sql) /** * @param $context - * @return closure + * @return \Closure */ public function getRowCountClosure($context) { diff --git a/library/Zend/Db/TableGateway/AbstractTableGateway.php b/library/Zend/Db/TableGateway/AbstractTableGateway.php index 94b685aa539..c648346078f 100644 --- a/library/Zend/Db/TableGateway/AbstractTableGateway.php +++ b/library/Zend/Db/TableGateway/AbstractTableGateway.php @@ -301,7 +301,7 @@ protected function executeInsert(Insert $insert) * Update * * @param array $set - * @param string|array|closure $where + * @param string|array|\Closure $where * @return int */ public function update($set, $where = null) diff --git a/library/Zend/Di/Di.php b/library/Zend/Di/Di.php index df8187b637f..7be36316b4c 100644 --- a/library/Zend/Di/Di.php +++ b/library/Zend/Di/Di.php @@ -551,7 +551,7 @@ protected function resolveAndCallInjectionMethodForInstance($instance, $method, * @param string $method * @param array $callTimeUserParams * @param string $alias - * @param int|bolean $methodRequirementType + * @param int|boolean $methodRequirementType * @param bool $isInstantiator * @throws Exception\MissingPropertyException * @throws Exception\CircularDependencyException diff --git a/library/Zend/Dom/DOMXPath.php b/library/Zend/Dom/DOMXPath.php index e67fd34719e..37a016ae80c 100644 --- a/library/Zend/Dom/DOMXPath.php +++ b/library/Zend/Dom/DOMXPath.php @@ -27,7 +27,7 @@ class DOMXPath extends \DOMXPath * raising an error * * @param string $expression The XPath expression to evaluate. - * @return DOMNodeList + * @return \DOMNodeList * @throws ErrorException */ public function queryWithErrorException($expression) diff --git a/library/Zend/Dom/Query.php b/library/Zend/Dom/Query.php index 89e7e9675bb..55142991696 100644 --- a/library/Zend/Dom/Query.php +++ b/library/Zend/Dom/Query.php @@ -298,7 +298,7 @@ public function registerXpathPhpFunctions($xpathPhpFunctions = true) * @param DOMDocument $document * @param string|array $xpathQuery * @return array - * @throws ErrorException If query cannot be executed + * @throws \ErrorException If query cannot be executed */ protected function getNodeList($document, $xpathQuery) { diff --git a/library/Zend/Feed/Reader/Reader.php b/library/Zend/Feed/Reader/Reader.php index 3205a04ec1c..c4860a8c627 100644 --- a/library/Zend/Feed/Reader/Reader.php +++ b/library/Zend/Feed/Reader/Reader.php @@ -266,7 +266,7 @@ public static function import($uri, $etag = null, $lastModified = null) * HTTP client implementations. * * @param string $uri - * @param Http\Client $client + * @param Http\ClientInterface $client * @return self * @throws Exception\RuntimeException if response is not an Http\ResponseInterface */ diff --git a/library/Zend/Feed/Writer/ExtensionManager.php b/library/Zend/Feed/Writer/ExtensionManager.php index 5310050a0d2..77d49a0dc31 100644 --- a/library/Zend/Feed/Writer/ExtensionManager.php +++ b/library/Zend/Feed/Writer/ExtensionManager.php @@ -60,7 +60,7 @@ public function __call($method, $args) * Get the named extension * * @param string $name - * @return Extension\AbstractEntry|Extension\AbstractFeed + * @return Extension\AbstractRenderer */ public function get($name) { diff --git a/library/Zend/Filter/DateTimeFormatter.php b/library/Zend/Filter/DateTimeFormatter.php index 9b0065d6af8..b24897b2f3e 100644 --- a/library/Zend/Filter/DateTimeFormatter.php +++ b/library/Zend/Filter/DateTimeFormatter.php @@ -23,7 +23,7 @@ class DateTimeFormatter extends AbstractFilter /** * Sets filter options * - * @param array|Traversable $options + * @param array|\Traversable $options */ public function __construct($options = null) { diff --git a/library/Zend/Filter/FilterChain.php b/library/Zend/Filter/FilterChain.php index 4202ffbe11c..cb74bda5fe5 100644 --- a/library/Zend/Filter/FilterChain.php +++ b/library/Zend/Filter/FilterChain.php @@ -10,6 +10,7 @@ namespace Zend\Filter; use Countable; +use Traversable; use Zend\Stdlib\PriorityQueue; class FilterChain extends AbstractFilter implements Countable @@ -52,7 +53,7 @@ public function __construct($options = null) */ public function setOptions($options) { - if (!is_array($options) && !$options instanceof \Traversable) { + if (!is_array($options) && !$options instanceof Traversable) { throw new Exception\InvalidArgumentException(sprintf( 'Expected array or Traversable; received "%s"', (is_object($options) ? get_class($options) : gettype($options)) diff --git a/library/Zend/Filter/Inflector.php b/library/Zend/Filter/Inflector.php index 0b18a5c77f5..4120a68f2ea 100644 --- a/library/Zend/Filter/Inflector.php +++ b/library/Zend/Filter/Inflector.php @@ -217,7 +217,7 @@ public function getTarget() /** * Set Target Reference * - * @param reference $target + * @param string $target * @return self */ public function setTargetReference(&$target) diff --git a/library/Zend/Form/FormElementManager.php b/library/Zend/Form/FormElementManager.php index f9ffaf9d36e..a97244f9d7a 100644 --- a/library/Zend/Form/FormElementManager.php +++ b/library/Zend/Form/FormElementManager.php @@ -11,6 +11,7 @@ use Zend\ServiceManager\AbstractPluginManager; use Zend\ServiceManager\ConfigInterface; +use Zend\ServiceManager\Exception\ServiceNotCreatedException; use Zend\ServiceManager\ServiceLocatorInterface; use Zend\Stdlib\InitializableInterface; @@ -153,7 +154,7 @@ public function get($name, $options = array(), $usePeeringServiceManagers = true * @param string $canonicalName * @param string $requestedName * @return null|\stdClass - * @throws Exception\ServiceNotCreatedException If resolved class does not exist + * @throws ServiceNotCreatedException If resolved class does not exist */ protected function createFromInvokable($canonicalName, $requestedName) { diff --git a/library/Zend/Form/InputFilterProviderFieldset.php b/library/Zend/Form/InputFilterProviderFieldset.php index 210b7b3705c..6c34f14f9b5 100644 --- a/library/Zend/Form/InputFilterProviderFieldset.php +++ b/library/Zend/Form/InputFilterProviderFieldset.php @@ -9,6 +9,7 @@ namespace Zend\Form; +use Traversable; use Zend\InputFilter\InputFilterProviderInterface; class InputFilterProviderFieldset extends Fieldset implements InputFilterProviderInterface diff --git a/library/Zend/Form/LabelAwareInterface.php b/library/Zend/Form/LabelAwareInterface.php index 54765ce8e37..57096d06e70 100644 --- a/library/Zend/Form/LabelAwareInterface.php +++ b/library/Zend/Form/LabelAwareInterface.php @@ -46,7 +46,7 @@ public function getLabelAttributes(); * * Implementation will decide if this will overwrite or merge. * - * @param array|Traversable $arrayOrTraversable + * @param array|\Traversable $arrayOrTraversable * @return self */ public function setLabelOptions($arrayOrTraversable); diff --git a/library/Zend/Http/Headers.php b/library/Zend/Http/Headers.php index 440b5be3275..d89fdb96972 100644 --- a/library/Zend/Http/Headers.php +++ b/library/Zend/Http/Headers.php @@ -24,7 +24,7 @@ class Headers implements Countable, Iterator { /** - * @var PluginClassLoader + * @var PluginClassLocator */ protected $pluginClassLoader = null; diff --git a/library/Zend/Log/Writer/AbstractWriter.php b/library/Zend/Log/Writer/AbstractWriter.php index 1f5c75c4674..bedef8568fc 100644 --- a/library/Zend/Log/Writer/AbstractWriter.php +++ b/library/Zend/Log/Writer/AbstractWriter.php @@ -67,7 +67,6 @@ abstract class AbstractWriter implements WriterInterface * - formatter: formatter for this writer * * @param array|Traversable $options - * @return Logger * @throws Exception\InvalidArgumentException */ public function __construct($options = null) diff --git a/library/Zend/Mail/Storage/Writable/Maildir.php b/library/Zend/Mail/Storage/Writable/Maildir.php index 1b269395514..e930ea04184 100644 --- a/library/Zend/Mail/Storage/Writable/Maildir.php +++ b/library/Zend/Mail/Storage/Writable/Maildir.php @@ -426,7 +426,7 @@ protected function _getInfoString(&$flags) /** * append a new message to mail storage * - * @param string|stream $message message as string or stream resource + * @param string|resource $message message as string or stream resource * @param null|string|\Zend\Mail\Storage\Folder $folder folder for new message, else current folder is taken * @param null|array $flags set flags for new message, else a default set is used * @param bool $recent handle this mail as if recent flag has been set, diff --git a/library/Zend/Mime/Part.php b/library/Zend/Mime/Part.php index 2fde6ccffce..98e46d9a7d2 100644 --- a/library/Zend/Mime/Part.php +++ b/library/Zend/Mime/Part.php @@ -68,7 +68,7 @@ public function isStream() * reading the content. very useful for large file attachments. * * @param string $EOL - * @return stream + * @return resource * @throws Exception\RuntimeException if not a stream or unable to append filter */ public function getEncodedStream($EOL = Mime::LINEEND) diff --git a/library/Zend/ModuleManager/ModuleManager.php b/library/Zend/ModuleManager/ModuleManager.php index 5d68f0a604f..2036764fe38 100644 --- a/library/Zend/ModuleManager/ModuleManager.php +++ b/library/Zend/ModuleManager/ModuleManager.php @@ -174,7 +174,7 @@ public function loadModule($module) /** * Load a module with the name - * @param Zend\EventManager\EventInterface $event + * @param \Zend\EventManager\EventInterface $event * @return mixed module instance * @throws Exception\RuntimeException */ diff --git a/library/Zend/Mvc/I18n/Translator.php b/library/Zend/Mvc/I18n/Translator.php index 73d3c23f5a1..71caf83ce32 100644 --- a/library/Zend/Mvc/I18n/Translator.php +++ b/library/Zend/Mvc/I18n/Translator.php @@ -18,12 +18,12 @@ class Translator implements ValidatorTranslatorInterface { /** - * @var I18nTranslator + * @var I18nTranslatorInterface */ protected $translator; /** - * @param I18nTranslator $translator + * @param I18nTranslatorInterface $translator */ public function __construct(I18nTranslatorInterface $translator) { diff --git a/library/Zend/Mvc/Router/Http/TranslatorAwareTreeRouteStack.php b/library/Zend/Mvc/Router/Http/TranslatorAwareTreeRouteStack.php index a1f30c56143..4caa4e7a461 100644 --- a/library/Zend/Mvc/Router/Http/TranslatorAwareTreeRouteStack.php +++ b/library/Zend/Mvc/Router/Http/TranslatorAwareTreeRouteStack.php @@ -11,6 +11,7 @@ use Zend\I18n\Translator\TranslatorInterface as Translator; use Zend\I18n\Translator\TranslatorAwareInterface; +use Zend\Mvc\Router\Exception; use Zend\Stdlib\RequestInterface as Request; /** diff --git a/library/Zend/Navigation/Page/AbstractPage.php b/library/Zend/Navigation/Page/AbstractPage.php index e34cd911030..d64a6d539aa 100644 --- a/library/Zend/Navigation/Page/AbstractPage.php +++ b/library/Zend/Navigation/Page/AbstractPage.php @@ -260,7 +260,7 @@ public static function factory($options) /** * Add static factory for self::factory function * - * @param type $callback Any callable variable + * @param callable $callback Any callable variable */ public static function addFactory($callback) { diff --git a/library/Zend/Navigation/Page/Uri.php b/library/Zend/Navigation/Page/Uri.php index 085c526d889..ebdc0f4e137 100644 --- a/library/Zend/Navigation/Page/Uri.php +++ b/library/Zend/Navigation/Page/Uri.php @@ -123,7 +123,7 @@ public function getRequest() * Sets request for assembling URLs * * @param Request $request - * @return Fluent interface, returns self + * @return self Fluent interface, returns self */ public function setRequest(Request $request = null) { diff --git a/library/Zend/Permissions/Acl/Assertion/AssertionAggregate.php b/library/Zend/Permissions/Acl/Assertion/AssertionAggregate.php index e74e562afca..4c7ad9369bf 100644 --- a/library/Zend/Permissions/Acl/Assertion/AssertionAggregate.php +++ b/library/Zend/Permissions/Acl/Assertion/AssertionAggregate.php @@ -95,7 +95,7 @@ public function getAssertionManager() * * @param string $mode * indicates how assertion chain result should interpreted (either 'all' or 'at_least_one') - * @throws Exception + * @throws InvalidArgumentException * * @return self */ diff --git a/library/Zend/Session/SaveHandler/MongoDB.php b/library/Zend/Session/SaveHandler/MongoDB.php index 2edabd282cd..5b21e49c4a2 100644 --- a/library/Zend/Session/SaveHandler/MongoDB.php +++ b/library/Zend/Session/SaveHandler/MongoDB.php @@ -51,7 +51,7 @@ class MongoDB implements SaveHandlerInterface * * @param Mongo|MongoClient $mongo * @param MongoDBOptions $options - * @throws Zend\Session\Exception\InvalidArgumentException + * @throws InvalidArgumentException */ public function __construct($mongo, MongoDBOptions $options) { diff --git a/library/Zend/Session/Service/StorageFactory.php b/library/Zend/Session/Service/StorageFactory.php index 6222e75adc7..66414268592 100644 --- a/library/Zend/Session/Service/StorageFactory.php +++ b/library/Zend/Session/Service/StorageFactory.php @@ -12,7 +12,7 @@ use Zend\ServiceManager\Exception\ServiceNotCreatedException; use Zend\ServiceManager\FactoryInterface; use Zend\ServiceManager\ServiceLocatorInterface; -use Zend\Session\Storage\Exception as SessionException; +use Zend\Session\Exception\ExceptionInterface as SessionException; use Zend\Session\Storage\Factory; use Zend\Session\Storage\StorageInterface; diff --git a/library/Zend/Soap/Server.php b/library/Zend/Soap/Server.php index 43f0c687f1a..190bec0e17e 100644 --- a/library/Zend/Soap/Server.php +++ b/library/Zend/Soap/Server.php @@ -720,7 +720,7 @@ public function getPersistence() * - stdClass; if so, calls __toString() and verifies XML * - string; if so, verifies XML * - * @param DOMDocument|DOMNode|SimpleXMLElement|stdClass|string $request + * @param DOMDocument|DOMNode|SimpleXMLElement|\stdClass|string $request * @return self * @throws Exception\InvalidArgumentException */ @@ -880,7 +880,7 @@ public function getSoap() * If no request is passed, pulls request using php:://input (for * cross-platform compatibility purposes). * - * @param DOMDocument|DOMNode|SimpleXMLElement|stdClass|string $request Optional request + * @param DOMDocument|DOMNode|SimpleXMLElement|\stdClass|string $request Optional request * @return void|string */ public function handle($request = null) @@ -999,7 +999,7 @@ public function registerFaultException($class) /** * Checks if provided fault name is registered as valid in this server. * - * @param $fault Name of a fault class + * @param string $fault Name of a fault class * @return bool */ public function isRegisteredAsFaultException($fault) diff --git a/library/Zend/Stdlib/PriorityList.php b/library/Zend/Stdlib/PriorityList.php index 9ed0ba41ebe..1664e193280 100644 --- a/library/Zend/Stdlib/PriorityList.php +++ b/library/Zend/Stdlib/PriorityList.php @@ -244,7 +244,7 @@ public function count() /** * Return list as array * - * @param type $raw + * @param int $flag * @return array */ public function toArray($flag = self::EXTR_DATA) diff --git a/library/Zend/Test/PHPUnit/Controller/AbstractControllerTestCase.php b/library/Zend/Test/PHPUnit/Controller/AbstractControllerTestCase.php index 4097fa80014..b834adb1747 100644 --- a/library/Zend/Test/PHPUnit/Controller/AbstractControllerTestCase.php +++ b/library/Zend/Test/PHPUnit/Controller/AbstractControllerTestCase.php @@ -707,7 +707,7 @@ public function assertNotTemplateName($templateName) /** * Recursively search a view model and it's children for the given templateName * - * @param ViewModel $viewModel + * @param \Zend\View\Model\ModelInterface $viewModel * @param string $templateName * @return boolean */ diff --git a/library/Zend/View/Helper/Placeholder/Container/AbstractStandalone.php b/library/Zend/View/Helper/Placeholder/Container/AbstractStandalone.php index 0e47599d104..009460569cd 100644 --- a/library/Zend/View/Helper/Placeholder/Container/AbstractStandalone.php +++ b/library/Zend/View/Helper/Placeholder/Container/AbstractStandalone.php @@ -365,7 +365,7 @@ public function offsetUnset($offset) /** * IteratorAggregate: get Iterator * - * @return Iterator + * @return \Iterator */ public function getIterator() { From 52f05c5a5308f82b4b1557a69d7339fe6ad0bb8f Mon Sep 17 00:00:00 2001 From: Michel Hunziker Date: Mon, 7 Apr 2014 11:04:17 +0200 Subject: [PATCH 2/3] Fix undefined class constant --- library/Zend/Di/Definition/Builder/InjectionMethod.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/Zend/Di/Definition/Builder/InjectionMethod.php b/library/Zend/Di/Definition/Builder/InjectionMethod.php index c0e3e60a234..a27f7b19226 100644 --- a/library/Zend/Di/Definition/Builder/InjectionMethod.php +++ b/library/Zend/Di/Definition/Builder/InjectionMethod.php @@ -106,7 +106,7 @@ public static function detectMethodRequirement($requirement) return Di::METHOD_IS_OPTIONAL; break; case "constructor": - return Di::MEHTOD_IS_CONSTRUCTOR; + return Di::METHOD_IS_CONSTRUCTOR; break; case "instantiator": return Di::METHOD_IS_INSTANTIATOR; From f74dcb6cbb76d9dc64ca9581b85efb1e60f75b21 Mon Sep 17 00:00:00 2001 From: Michel Hunziker Date: Mon, 7 Apr 2014 11:39:15 +0200 Subject: [PATCH 3/3] Fix possible undefined methods in inherited classes --- library/Zend/Ldap/Attribute.php | 16 ++++++++-------- library/Zend/Serializer/Serializer.php | 2 +- .../Hydrator/Filter/OptionalParametersFilter.php | 2 +- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/library/Zend/Ldap/Attribute.php b/library/Zend/Ldap/Attribute.php index c2984f3c70a..552616ba256 100644 --- a/library/Zend/Ldap/Attribute.php +++ b/library/Zend/Ldap/Attribute.php @@ -37,13 +37,13 @@ public static function setAttribute(array &$data, $attribName, $value, $append = $valArray = array(); if (is_array($value) || ($value instanceof \Traversable)) { foreach ($value as $v) { - $v = static::valueToLdap($v); + $v = self::valueToLdap($v); if ($v !== null) { $valArray[] = $v; } } } elseif ($value !== null) { - $value = static::valueToLdap($value); + $value = self::valueToLdap($value); if ($value !== null) { $valArray[] = $value; } @@ -76,14 +76,14 @@ public static function getAttribute(array $data, $attribName, $index = null) } $retArray = array(); foreach ($data[$attribName] as $v) { - $retArray[] = static::valueFromLdap($v); + $retArray[] = self::valueFromLdap($v); } return $retArray; } elseif (is_int($index)) { if (!isset($data[$attribName])) { return null; } elseif ($index >= 0 && $index < count($data[$attribName])) { - return static::valueFromLdap($data[$attribName][$index]); + return self::valueFromLdap($data[$attribName][$index]); } else { return null; } @@ -295,13 +295,13 @@ public static function setDateTimeAttribute( $convertedValues = array(); if (is_array($value) || ($value instanceof \Traversable)) { foreach ($value as $v) { - $v = static::valueToLdapDateTime($v, $utc); + $v = self::valueToLdapDateTime($v, $utc); if ($v !== null) { $convertedValues[] = $v; } } } elseif ($value !== null) { - $value = static::valueToLdapDateTime($value, $utc); + $value = self::valueToLdapDateTime($value, $utc); if ($value !== null) { $convertedValues[] = $value; } @@ -336,13 +336,13 @@ public static function getDateTimeAttribute(array $data, $attribName, $index = n $values = static::getAttribute($data, $attribName, $index); if (is_array($values)) { for ($i = 0, $count = count($values); $i < $count; $i++) { - $newVal = static::valueFromLdapDateTime($values[$i]); + $newVal = self::valueFromLdapDateTime($values[$i]); if ($newVal !== null) { $values[$i] = $newVal; } } } else { - $newVal = static::valueFromLdapDateTime($values); + $newVal = self::valueFromLdapDateTime($values); if ($newVal !== null) { $values = $newVal; } diff --git a/library/Zend/Serializer/Serializer.php b/library/Zend/Serializer/Serializer.php index 5cc6bdc55bc..5cc1184f4e1 100644 --- a/library/Zend/Serializer/Serializer.php +++ b/library/Zend/Serializer/Serializer.php @@ -18,7 +18,7 @@ abstract class Serializer * * @var null|AdapterPluginManager */ - private static $adapters = null; + protected static $adapters = null; /** * The default adapter. diff --git a/library/Zend/Stdlib/Hydrator/Filter/OptionalParametersFilter.php b/library/Zend/Stdlib/Hydrator/Filter/OptionalParametersFilter.php index b78a21b1d25..46401590506 100644 --- a/library/Zend/Stdlib/Hydrator/Filter/OptionalParametersFilter.php +++ b/library/Zend/Stdlib/Hydrator/Filter/OptionalParametersFilter.php @@ -25,7 +25,7 @@ class OptionalParametersFilter implements FilterInterface * * @var bool[] */ - private static $propertiesCache = array(); + protected static $propertiesCache = array(); /** * {@inheritDoc}