@@ -58,7 +58,7 @@ |
||
| 58 | 58 | * Set table names SELECT query should be performed for. Table names can be provided with |
| 59 | 59 | * specified alias (AS construction). |
| 60 | 60 | * |
| 61 | - * @param array|string|mixed $tables Array of names, comma separated string or set of |
|
| 61 | + * @param string $tables Array of names, comma separated string or set of |
|
| 62 | 62 | * parameters. |
| 63 | 63 | * @return $this |
| 64 | 64 | */ |
@@ -232,7 +232,7 @@ discard block |
||
| 232 | 232 | * such methods. |
| 233 | 233 | * |
| 234 | 234 | * @see AbstractWhere |
| 235 | - * @param string|mixed $joined Joined column or expression. |
|
| 235 | + * @param string $joined Joined column or expression. |
|
| 236 | 236 | * @param mixed $variousA Operator or value. |
| 237 | 237 | * @param mixed $variousB Value, if operator specified. |
| 238 | 238 | * @param mixed $variousC Required only in between statements. |
@@ -300,7 +300,7 @@ discard block |
||
| 300 | 300 | * @param string $joiner Boolean joiner (AND | OR). |
| 301 | 301 | * @param array $parameters Set of parameters collected from where functions. |
| 302 | 302 | * @param array $tokens Array to aggregate compiled tokens. Reference. |
| 303 | - * @param \Closure|null $wrapper Callback or closure used to wrap/collect every potential |
|
| 303 | + * @param callable $wrapper Callback or closure used to wrap/collect every potential |
|
| 304 | 304 | * parameter. |
| 305 | 305 | * @throws BuilderException |
| 306 | 306 | */ |
@@ -318,7 +318,7 @@ discard block |
||
| 318 | 318 | */ |
| 319 | 319 | private function onWrapper() |
| 320 | 320 | { |
| 321 | - return function ($parameter) { |
|
| 321 | + return function($parameter) { |
|
| 322 | 322 | if ($parameter instanceof FragmentInterface) { |
| 323 | 323 | return $parameter; |
| 324 | 324 | } |
@@ -334,7 +334,7 @@ discard block |
||
| 334 | 334 | */ |
| 335 | 335 | private function whereWrapper() |
| 336 | 336 | { |
| 337 | - return function ($parameter) { |
|
| 337 | + return function($parameter) { |
|
| 338 | 338 | if ($parameter instanceof FragmentInterface) { |
| 339 | 339 | //We are only not creating bindings for plan fragments |
| 340 | 340 | if (!$parameter instanceof ParameterInterface && !$parameter instanceof QueryBuilder) { |
@@ -228,7 +228,7 @@ |
||
| 228 | 228 | * Execute statement. |
| 229 | 229 | * |
| 230 | 230 | * @param string $statement |
| 231 | - * @param array $parameters |
|
| 231 | + * @param string[] $parameters |
|
| 232 | 232 | * @return \PDOStatement |
| 233 | 233 | */ |
| 234 | 234 | protected function run($statement, array $parameters = []) |
@@ -126,7 +126,7 @@ |
||
| 126 | 126 | * |
| 127 | 127 | * @param array $columns Array of columns. |
| 128 | 128 | * @param array $rowsets Array of rowsets. |
| 129 | - * @return mixed |
|
| 129 | + * @return integer |
|
| 130 | 130 | */ |
| 131 | 131 | public function batchInsert(array $columns = [], array $rowsets = []) |
| 132 | 132 | { |
@@ -138,7 +138,7 @@ discard block |
||
| 138 | 138 | /** |
| 139 | 139 | * Get composition parent. |
| 140 | 140 | * |
| 141 | - * @return Document|null |
|
| 141 | + * @return EntityInterface |
|
| 142 | 142 | */ |
| 143 | 143 | public function getParent() |
| 144 | 144 | { |
@@ -485,7 +485,7 @@ discard block |
||
| 485 | 485 | /** |
| 486 | 486 | * {@inheritdoc} |
| 487 | 487 | * |
| 488 | - * @return Document[] |
|
| 488 | + * @return \ArrayIterator |
|
| 489 | 489 | */ |
| 490 | 490 | public function getIterator() |
| 491 | 491 | { |
@@ -577,7 +577,7 @@ discard block |
||
| 577 | 577 | * Example: |
| 578 | 578 | * $user->cards->findOne(['active' => true]); |
| 579 | 579 | * |
| 580 | - * @param array|DocumentEntity $query |
|
| 580 | + * @param DocumentEntity $query |
|
| 581 | 581 | * @return null|DocumentEntity |
| 582 | 582 | */ |
| 583 | 583 | public function findOne($query = []) |
@@ -595,7 +595,7 @@ discard block |
||
| 595 | 595 | * |
| 596 | 596 | * @param DocumentEntity $document |
| 597 | 597 | * @param bool $resetState Set to true to reset compositor solid state. |
| 598 | - * @return $this|DocumentEntity[] |
|
| 598 | + * @return Compositor |
|
| 599 | 599 | * @throws CompositorException |
| 600 | 600 | */ |
| 601 | 601 | public function push(DocumentEntity $document, $resetState = true) |
@@ -630,7 +630,7 @@ discard block |
||
| 630 | 630 | * |
| 631 | 631 | * @param array|DocumentEntity $query |
| 632 | 632 | * @param bool $resetState Set to true to reset compositor solid state. |
| 633 | - * @return $this|DocumentEntity[] |
|
| 633 | + * @return Compositor |
|
| 634 | 634 | * @throws CompositorException |
| 635 | 635 | */ |
| 636 | 636 | public function pull($query, $resetState = true) |
@@ -675,7 +675,7 @@ discard block |
||
| 675 | 675 | * |
| 676 | 676 | * @param DocumentEntity $document |
| 677 | 677 | * @param bool $resetState Set to true to reset compositor solid state. |
| 678 | - * @return $this|DocumentEntity[] |
|
| 678 | + * @return Compositor |
|
| 679 | 679 | * @throws CompositorException |
| 680 | 680 | */ |
| 681 | 681 | public function addToSet(DocumentEntity $document, $resetState = true) |
@@ -99,7 +99,7 @@ |
||
| 99 | 99 | * Method will not affect state of pre-loaded data! Use reset() method to do that. |
| 100 | 100 | * |
| 101 | 101 | * @see sync() |
| 102 | - * @param mixed $outer |
|
| 102 | + * @param \Spiral\ORM\RecordInterface $outer |
|
| 103 | 103 | * @param array $pivotData |
| 104 | 104 | */ |
| 105 | 105 | public function link($outer, array $pivotData = []) |
@@ -98,7 +98,7 @@ discard block |
||
| 98 | 98 | /** |
| 99 | 99 | * Related source class. |
| 100 | 100 | * |
| 101 | - * @return string|null |
|
| 101 | + * @return string |
|
| 102 | 102 | */ |
| 103 | 103 | public function getSource() |
| 104 | 104 | { |
@@ -153,7 +153,7 @@ discard block |
||
| 153 | 153 | * value using class name and Doctrine inflector. |
| 154 | 154 | * |
| 155 | 155 | * @see Record::$table |
| 156 | - * @return mixed |
|
| 156 | + * @return string |
|
| 157 | 157 | */ |
| 158 | 158 | public function getTable() |
| 159 | 159 | { |
@@ -172,7 +172,7 @@ discard block |
||
| 172 | 172 | * Get database where record data should be stored in. Database alias must be resolved. |
| 173 | 173 | * |
| 174 | 174 | * @see Record::$database |
| 175 | - * @return mixed |
|
| 175 | + * @return string |
|
| 176 | 176 | */ |
| 177 | 177 | public function getDatabase() |
| 178 | 178 | { |
@@ -487,7 +487,7 @@ discard block |
||
| 487 | 487 | * @param AbstractColumn $column |
| 488 | 488 | * @param string $definition |
| 489 | 489 | * @param mixed $default Default value declared by record schema. |
| 490 | - * @return mixed |
|
| 490 | + * @return AbstractColumn |
|
| 491 | 491 | * @throws DefinitionException |
| 492 | 492 | * @throws \Spiral\Database\Exceptions\SchemaException |
| 493 | 493 | */ |
@@ -42,7 +42,7 @@ discard block |
||
| 42 | 42 | * @param array|\Closure $where Selection WHERE statement. |
| 43 | 43 | * @param array $load Array or relations to be pre-loaded. |
| 44 | 44 | * @param array $orderBy Sort by conditions. |
| 45 | - * @return RecordEntity|null |
|
| 45 | + * @return null|\Spiral\ORM\RecordInterface |
|
| 46 | 46 | */ |
| 47 | 47 | public static function findOne($where = [], array $load = [], array $orderBy = []) |
| 48 | 48 | { |
@@ -62,7 +62,7 @@ discard block |
||
| 62 | 62 | * |
| 63 | 63 | * @param mixed $primaryKey Primary key. |
| 64 | 64 | * @param array $load Array or relations to be pre-loaded. |
| 65 | - * @return RecordEntity|null |
|
| 65 | + * @return null|\Spiral\ORM\RecordInterface |
|
| 66 | 66 | */ |
| 67 | 67 | public static function findByPK($primaryKey, array $load = []) |
| 68 | 68 | { |
@@ -33,7 +33,7 @@ discard block |
||
| 33 | 33 | /** |
| 34 | 34 | * New instance of ReflectionArgument. |
| 35 | 35 | * |
| 36 | - * @param mixed $type |
|
| 36 | + * @param string $type |
|
| 37 | 37 | * @param mixed $value |
| 38 | 38 | */ |
| 39 | 39 | public function __construct($type, $value) |
@@ -43,7 +43,7 @@ discard block |
||
| 43 | 43 | } |
| 44 | 44 | |
| 45 | 45 | /** |
| 46 | - * @return mixed |
|
| 46 | + * @return integer |
|
| 47 | 47 | */ |
| 48 | 48 | public function getType() |
| 49 | 49 | { |
@@ -15,10 +15,10 @@ |
||
| 15 | 15 | /** |
| 16 | 16 | * Argument types. |
| 17 | 17 | */ |
| 18 | - const CONSTANT = 'constant'; //Scalar constant and not variable. |
|
| 19 | - const VARIABLE = 'variable'; //PHP variable |
|
| 18 | + const CONSTANT = 'constant'; //Scalar constant and not variable. |
|
| 19 | + const VARIABLE = 'variable'; //PHP variable |
|
| 20 | 20 | const EXPRESSION = 'expression'; //PHP code (expression). |
| 21 | - const STRING = 'string'; //Simple scalar string, can be fetched using stringValue(). |
|
| 21 | + const STRING = 'string'; //Simple scalar string, can be fetched using stringValue(). |
|
| 22 | 22 | |
| 23 | 23 | /** |
| 24 | 24 | * @var int |