Skip to content
Permalink
Browse files

Fix up doblocks to be of more concrete type arrays

  • Loading branch information...
dereuromark committed Oct 23, 2016
1 parent 752d0fe commit 7c23c086009210fdaab4bfd4852dc91724fa2cf6
@@ -102,7 +102,8 @@ class Cache
/**
* Whether to reset the settings with the next call to Cache::set();
*
* @var array
* @deprecated Not used anymore
* @var bool
*/
protected static $_reset = false;
@@ -27,7 +27,7 @@ class ApcEngine extends CacheEngine
* Contains the compiled group names
* (prefixed with the global configuration prefix)
*
* @var array
* @var string[]
*/
protected $_compiledGroupNames = [];
@@ -45,15 +45,15 @@ class Configure
/**
* Configured engine classes, used to load config files from resources
*
* @var array
* @see \Cake\Core\Configure::load()
* @var \Cake\Core\Configure\ConfigEngineInterface[]
*/
protected static $_engines = [];
/**
* Flag to track whether or not ini_set exists.
*
* @return void
* @var bool|null
*/
protected static $_hasIniSet = null;
@@ -238,7 +238,7 @@ public static function config($name, ConfigEngineInterface $engine)
* Gets the names of the configured Engine objects.
*
* @param string|null $name Engine name.
* @return array Array of the configured Engine objects.
* @return array|bool Array of the configured Engine objects, bool for specific name.
*/
public static function configured($name = null)
{
@@ -38,7 +38,7 @@ class Exception extends RuntimeException
/**
* Array of headers to be passed to Cake\Network\Response::header()
*
* @var array
* @var array|null
*/
protected $_responseHeaders = null;
@@ -40,7 +40,7 @@ abstract class ObjectRegistry
/**
* Map of loaded objects.
*
* @var array
* @var object[]
*/
protected $_loaded = [];
@@ -64,7 +64,7 @@ class Comparison implements ExpressionInterface, FieldInterface
* A cached list of ExpressionInterface objects that were
* found in the value for this expression.
*
* @var array
* @var \Cake\Database\ExpressionInterface[]
*/
protected $_valueExpressions = [];
@@ -54,7 +54,7 @@ trait QueryTrait
* List of formatter classes or callbacks that will post-process the
* results when fetched
*
* @var array
* @var callable[]
*/
protected $_formatters = [];
@@ -63,28 +63,28 @@ class RulesChecker
/**
* The list of rules to be checked on both create and update operations
*
* @var array
* @var callable[]
*/
protected $_rules = [];
/**
* The list of rules to check during create operations
*
* @var array
* @var callable[]
*/
protected $_createRules = [];
/**
* The list of rules to check during update operations
*
* @var array
* @var callable[]
*/
protected $_updateRules = [];
/**
* The list of rules to check during delete operations
*
* @var array
* @var callable[]
*/
protected $_deleteRules = [];
@@ -56,7 +56,7 @@ public function add(Event $event)
*
* @link http://php.net/manual/en/arrayaccess.offsetexists.php
* @param mixed $offset An offset to check for.
* @return boole True on success or false on failure.
* @return bool True on success or false on failure.
*/
public function offsetExists($offset)
{
@@ -37,7 +37,7 @@ class ActionDispatcher
/**
* Attached routing filters
*
* @var array
* @var \Cake\Event\EventListenerInterface[]
*/
protected $filters = [];
@@ -53,7 +53,7 @@ class ActionDispatcher
*
* @param \Cake\Http\ControllerFactory|null $factory A controller factory instance.
* @param \Cake\Event\EventManager|null $eventManager An event manager if you want to inject one.
* @param array $filters The list of filters to include.
* @param \Cake\Event\EventListenerInterface[] $filters The list of filters to include.
*/
public function __construct($factory = null, $eventManager = null, array $filters = [])
{
@@ -71,7 +71,7 @@ public function __construct($factory = null, $eventManager = null, array $filter
*
* @param \Cake\Network\Request $request The request to dispatch.
* @param \Cake\Network\Response $response The response to dispatch.
* @return \Cake\Network\Response a modified/replaced response.
* @return \Cake\Network\Response A modified/replaced response.
*/
public function dispatch(Request $request, Response $response)
{
@@ -50,7 +50,7 @@ class FormData implements Countable
/**
* The parts in the form data.
*
* @var array
* @var \Cake\Http\Client\FormDataPart[]
*/
protected $_parts = [];
@@ -505,7 +505,7 @@ public function body($parser = null)
*/
protected function _getJson()
{
if (!empty($this->_json)) {
if ($this->_json) {
return $this->_json;
}
@@ -519,7 +519,7 @@ protected function _getJson()
*/
protected function _getXml()
{
if (!empty($this->_xml)) {
if ($this->_xml) {
return $this->_xml;
}
libxml_use_internal_errors();
@@ -35,7 +35,7 @@ class MiddlewareQueue implements Countable
/**
* The queue of middleware callables.
*
* @var array
* @var callable[]
*/
protected $callables = [];
@@ -27,15 +27,15 @@ class ChainMessagesLoader
/**
* The list of callables to execute one after another for loading messages
*
* @var array
* @var callable[]
*/
protected $_loaders = [];
/**
* Receives a list of callable functions or objects that will be executed
* one after another until one of them returns a non-empty translations package
*
* @param array $loaders List of callables to execute
* @param callable[] $loaders List of callables to execute
*/
public function __construct(array $loaders)
{
@@ -34,9 +34,9 @@ class TranslatorRegistry extends TranslatorLocator
* packages where none can be found for the combination of translator
* name and locale.
*
* @var array
* @var callable[]
*/
protected $_loaders;
protected $_loaders = [];
/**
* Fallback loader name
@@ -60,7 +60,7 @@ class SyslogLog extends BaseLog
/**
* Used to map the string names back to their LOG_* constants
*
* @var array
* @var int[]
*/
protected $_levelMap = [
'emergency' => LOG_EMERG,
@@ -187,7 +187,11 @@ abstract class Association
*
* @var array
*/
protected $_validStrategies = [self::STRATEGY_JOIN, self::STRATEGY_SELECT, self::STRATEGY_SUBQUERY];
protected $_validStrategies = [
self::STRATEGY_JOIN,
self::STRATEGY_SELECT,
self::STRATEGY_SUBQUERY
];
/**
* Constructor. Subclasses can override _options function to get the original
@@ -702,7 +706,7 @@ public function find($type = null, array $options = [])
*/
public function exists($conditions)
{
if (!empty($this->_conditions)) {
if ($this->_conditions) {
$conditions = $this
->find('all', ['conditions' => $conditions])
->clause('where');
@@ -805,7 +809,7 @@ protected function _appendFields($query, $surrogate, $options)
$fields = array_merge((array)$fields, $target->schema()->columns());
}
if (!empty($fields)) {
if ($fields) {
$query->select($query->aliasFields($fields, $target->alias()));
}
$query->addDefaultTypes($target);
@@ -36,7 +36,10 @@ class BelongsTo extends Association
*
* @var array
*/
protected $_validStrategies = [self::STRATEGY_JOIN, self::STRATEGY_SELECT];
protected $_validStrategies = [
self::STRATEGY_JOIN,
self::STRATEGY_SELECT
];
/**
* Sets the name of the field representing the foreign key to the target table.
@@ -120,7 +120,10 @@ class BelongsToMany extends Association
*
* @var array
*/
protected $_validStrategies = [self::STRATEGY_SELECT, self::STRATEGY_SUBQUERY];
protected $_validStrategies = [
self::STRATEGY_SELECT,
self::STRATEGY_SUBQUERY
];
/**
* Whether the records on the joint table should be removed when a record
@@ -62,7 +62,10 @@ class HasMany extends Association
*
* @var array
*/
protected $_validStrategies = [self::STRATEGY_SELECT, self::STRATEGY_SUBQUERY];
protected $_validStrategies = [
self::STRATEGY_SELECT,
self::STRATEGY_SUBQUERY
];
/**
* Saving strategy that will only append to the links set
@@ -36,7 +36,10 @@ class HasOne extends Association
*
* @var array
*/
protected $_validStrategies = [self::STRATEGY_JOIN, self::STRATEGY_SELECT];
protected $_validStrategies = [
self::STRATEGY_JOIN,
self::STRATEGY_SELECT
];
/**
* Sets the name of the field representing the foreign key to the target table.
@@ -36,15 +36,15 @@ class TableLocator implements LocatorInterface
/**
* Instances that belong to the registry.
*
* @var array
* @var \Cake\ORM\Table[]
*/
protected $_instances = [];
/**
* Contains a list of Table objects that were created out of the
* built-in Table class. The list is indexed by table alias
*
* @var array
* @var \Cake\ORM\Table[]
*/
protected $_fallbacked = [];
@@ -244,7 +244,7 @@ public function clear()
* debugging common mistakes when setting up associations or created new table
* classes.
*
* @return array
* @return \Cake\ORM\Table[]
*/
public function genericInstances()
{
@@ -33,7 +33,7 @@ class Dispatcher
/**
* Connected filter objects
*
* @var array
* @var \Cake\Event\EventListenerInterface[]
*/
protected $_filters = [];
@@ -83,7 +83,7 @@ public function addFilter(EventListenerInterface $filter)
/**
* Get the list of connected filters.
*
* @return array
* @return \Cake\Event\EventListenerInterface[]
*/
public function filters()
{
@@ -27,7 +27,7 @@ class DispatcherFactory
/**
* Stack of middleware to apply to dispatchers.
*
* @var array
* @var \Cake\Routing\DispatcherFilter[]
*/
protected static $_stack = [];
@@ -91,7 +91,7 @@ public static function create()
/**
* Get the connected dispatcher filters.
*
* @return array
* @return \Cake\Routing\DispatcherFilter[]
*/
public static function filters()
{
@@ -148,7 +148,7 @@ class Router
* The stack of URL filters to apply against routing URLs before passing the
* parameters to the route collection.
*
* @var array
* @var callable[]
*/
protected static $_urlFilters = [];
@@ -51,7 +51,7 @@ class ExtractTask extends Shell
/**
* Current file being processed
*
* @var string
* @var string|null
*/
protected $_file = null;
@@ -79,7 +79,7 @@ class ExtractTask extends Shell
/**
* Destination path
*
* @var string
* @var string|null
*/
protected $_output = null;
Oops, something went wrong.

0 comments on commit 7c23c08

Please sign in to comment.
You can’t perform that action at this time.