@@ -442,7 +442,7 @@ |
||
| 442 | 442 | /** |
| 443 | 443 | * Multiplies this time interval with a scalar and returns the result as a new time interval object. |
| 444 | 444 | * |
| 445 | - * @param number $multiplier |
|
| 445 | + * @param integer $multiplier |
|
| 446 | 446 | * @return TimeInterval |
| 447 | 447 | */ |
| 448 | 448 | public function multiply($multiplier): TimeInterval |
@@ -1,5 +1,5 @@ |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types=1); |
|
| 2 | +declare(strict_types = 1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Ivory\Value; |
| 5 | 5 | |
@@ -18,6 +18,9 @@ |
||
| 18 | 18 | */ |
| 19 | 19 | trait RelationMacros |
| 20 | 20 | { |
| 21 | + /** |
|
| 22 | + * @param string[] $columns |
|
| 23 | + */ |
|
| 21 | 24 | abstract public function project($columns): IRelation; |
| 22 | 25 | |
| 23 | 26 | abstract public function tuple(int $offset = 0): ITuple; |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types=1); |
|
| 2 | +declare(strict_types = 1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Ivory\Relation; |
| 5 | 5 | |
@@ -43,7 +43,7 @@ discard block |
||
| 43 | 43 | return $result; |
| 44 | 44 | } |
| 45 | 45 | |
| 46 | - public function toSet($colOffsetOrNameOrEvaluator, ?ISet $set = null): ISet |
|
| 46 | + public function toSet($colOffsetOrNameOrEvaluator, ?ISet $set = null) : ISet |
|
| 47 | 47 | { |
| 48 | 48 | if ($set === null) { |
| 49 | 49 | $set = new DictionarySet(); |
@@ -301,6 +301,9 @@ |
||
| 301 | 301 | { |
| 302 | 302 | private $refresher; |
| 303 | 303 | |
| 304 | + /** |
|
| 305 | + * @param \Closure $refresher |
|
| 306 | + */ |
|
| 304 | 307 | public function __construct($refresher) |
| 305 | 308 | { |
| 306 | 309 | $this->refresher = $refresher; |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types=1); |
|
| 2 | +declare(strict_types = 1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Ivory\Connection\Config; |
| 5 | 5 | |
@@ -301,7 +301,7 @@ discard block |
||
| 301 | 301 | ); |
| 302 | 302 | } |
| 303 | 303 | |
| 304 | - private static function createTxConfig(string $isolationLevel, ?bool $readOnly, ?bool $deferrable): TxConfig |
|
| 304 | + private static function createTxConfig(string $isolationLevel, ?bool $readOnly, ?bool $deferrable) : TxConfig |
|
| 305 | 305 | { |
| 306 | 306 | $txConf = new TxConfig(); |
| 307 | 307 | $txConf->setReadOnly($readOnly); |
@@ -10,7 +10,7 @@ |
||
| 10 | 10 | * |
| 11 | 11 | * @param string $pattern |
| 12 | 12 | * @param callable $callback |
| 13 | - * @param string|string[] $subject |
|
| 13 | + * @param string $subject |
|
| 14 | 14 | * @param int $limit |
| 15 | 15 | * @param int|null $count |
| 16 | 16 | * @return string|string[] depending on whether <tt>$subject</tt> is <tt>string</tt> or <tt>array</tt>, |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types=1); |
|
| 2 | +declare(strict_types = 1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Ivory\Utils; |
| 5 | 5 | |
@@ -23,7 +23,7 @@ discard block |
||
| 23 | 23 | callable $callback, |
| 24 | 24 | $subject, |
| 25 | 25 | int $limit = -1, |
| 26 | - int &$count = null |
|
| 26 | + int & $count = null |
|
| 27 | 27 | ) |
| 28 | 28 | { |
| 29 | 29 | if (is_array($subject)) { |
@@ -42,7 +42,7 @@ discard block |
||
| 42 | 42 | callable $callback, |
| 43 | 43 | string $subject, |
| 44 | 44 | int $limit = -1, |
| 45 | - int &$count = null |
|
| 45 | + int & $count = null |
|
| 46 | 46 | ): string |
| 47 | 47 | { |
| 48 | 48 | $count = 0; |
@@ -17,8 +17,8 @@ |
||
| 17 | 17 | /** |
| 18 | 18 | * Creates a new box from a corner and its opposite corner, each as either a {@link Point} or a pair of coordinates. |
| 19 | 19 | * |
| 20 | - * @param Point|float[] $corner |
|
| 21 | - * @param Point|float[] $oppositeCorner |
|
| 20 | + * @param Point|null $corner |
|
| 21 | + * @param Point|null $oppositeCorner |
|
| 22 | 22 | * @return Box |
| 23 | 23 | */ |
| 24 | 24 | public static function fromOppositeCorners($corner, $oppositeCorner): Box |
@@ -1,5 +1,5 @@ |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types=1); |
|
| 2 | +declare(strict_types = 1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Ivory\Value; |
| 5 | 5 | |
@@ -15,7 +15,7 @@ |
||
| 15 | 15 | /** |
| 16 | 16 | * Creates a new circle by its center point and radius. |
| 17 | 17 | * |
| 18 | - * @param Point|float[] $center the center point |
|
| 18 | + * @param Point|null $center the center point |
|
| 19 | 19 | * @param float $radius radius of the circle |
| 20 | 20 | * @return Circle |
| 21 | 21 | */ |
@@ -1,5 +1,5 @@ |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types=1); |
|
| 2 | +declare(strict_types = 1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Ivory\Value; |
| 5 | 5 | |
@@ -17,8 +17,8 @@ |
||
| 17 | 17 | /** |
| 18 | 18 | * Creates a new line segment from its start and end point, each as either a {@link Point} or a pair of coordinates. |
| 19 | 19 | * |
| 20 | - * @param Point|float[] $start |
|
| 21 | - * @param Point|float[] $end |
|
| 20 | + * @param Point|null $start |
|
| 21 | + * @param Point|null $end |
|
| 22 | 22 | * @return LineSegment |
| 23 | 23 | */ |
| 24 | 24 | public static function fromEndpoints($start, $end): LineSegment |
@@ -1,5 +1,5 @@ |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types=1); |
|
| 2 | +declare(strict_types = 1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Ivory\Value; |
| 5 | 5 | |
@@ -35,6 +35,7 @@ discard block |
||
| 35 | 35 | * |
| 36 | 36 | * @param string|string[] one or more names of parameters the cached values of which to invalidate; |
| 37 | 37 | * <tt>null</tt> invalidates everything |
| 38 | + * @return void |
|
| 38 | 39 | */ |
| 39 | 40 | function invalidateCache($paramName = null): void; |
| 40 | 41 | |
@@ -47,6 +48,7 @@ discard block |
||
| 47 | 48 | * |
| 48 | 49 | * @param string|string[] $paramName one or more names of parameters to disabled caching values of; |
| 49 | 50 | * <tt>null</tt> disables the caching altogether |
| 51 | + * @return void |
|
| 50 | 52 | */ |
| 51 | 53 | function disableCaching($paramName = null): void; |
| 52 | 54 | |
@@ -58,6 +60,7 @@ discard block |
||
| 58 | 60 | * argument (which is the default). |
| 59 | 61 | * |
| 60 | 62 | * @param string|string[] $paramName |
| 63 | + * @return void |
|
| 61 | 64 | */ |
| 62 | 65 | function enableCaching($paramName = null): void; |
| 63 | 66 | } |
@@ -116,6 +116,10 @@ |
||
| 116 | 116 | return new $exClass($resultHandler, $query); |
| 117 | 117 | } |
| 118 | 118 | |
| 119 | + /** |
|
| 120 | + * @param resource $resultHandler |
|
| 121 | + * @param StatementExceptionFactory $fallbackFactory |
|
| 122 | + */ |
|
| 119 | 123 | private function inferExceptionClass($resultHandler, ?StatementExceptionFactory $fallbackFactory = null): string |
| 120 | 124 | { |
| 121 | 125 | if ($this->bySqlStateCodeAndMessage || $this->bySqlStateCode || $this->bySqlStateClass) { |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -declare(strict_types=1); |
|
| 2 | +declare(strict_types = 1); |
|
| 3 | 3 | |
| 4 | 4 | namespace Ivory\Exception; |
| 5 | 5 | |
@@ -110,13 +110,13 @@ discard block |
||
| 110 | 110 | $resultHandler, |
| 111 | 111 | string $query, |
| 112 | 112 | ?StatementExceptionFactory $fallbackFactory = null |
| 113 | - ): StatementException { |
|
| 113 | + ) : StatementException { |
|
| 114 | 114 | $exClass = $this->inferExceptionClass($resultHandler, $fallbackFactory); |
| 115 | 115 | assert(is_a($exClass, StatementException::class, true)); |
| 116 | 116 | return new $exClass($resultHandler, $query); |
| 117 | 117 | } |
| 118 | 118 | |
| 119 | - private function inferExceptionClass($resultHandler, ?StatementExceptionFactory $fallbackFactory = null): string |
|
| 119 | + private function inferExceptionClass($resultHandler, ?StatementExceptionFactory $fallbackFactory = null) : string |
|
| 120 | 120 | { |
| 121 | 121 | if ($this->bySqlStateCodeAndMessage || $this->bySqlStateCode || $this->bySqlStateClass) { |
| 122 | 122 | $sqlStateCode = pg_result_error_field($resultHandler, PGSQL_DIAG_SQLSTATE); |