@@ -30,18 +30,18 @@ |
||
| 30 | 30 | if (is_callable($type)) { |
| 31 | 31 | $this->validateTypeFct = $type; |
| 32 | 32 | } else { |
| 33 | - $this->validateTypeFct = function ($object) use ($type) { |
|
| 33 | + $this->validateTypeFct = function($object) use ($type) { |
|
| 34 | 34 | return ($object instanceof $type); |
| 35 | 35 | }; |
| 36 | 36 | } |
| 37 | 37 | |
| 38 | 38 | if ($equalsFct === null) { |
| 39 | 39 | if (is_callable($type)) { |
| 40 | - $this->equalsFct = function ($obj1, $obj2) { |
|
| 40 | + $this->equalsFct = function($obj1, $obj2) { |
|
| 41 | 41 | return $obj1 === $obj2; |
| 42 | 42 | }; |
| 43 | 43 | } else { |
| 44 | - $this->equalsFct = function ($obj1, $obj2) { |
|
| 44 | + $this->equalsFct = function($obj1, $obj2) { |
|
| 45 | 45 | return $obj1->equals($obj2); |
| 46 | 46 | }; |
| 47 | 47 | } |
@@ -18,16 +18,16 @@ |
||
| 18 | 18 | */ |
| 19 | 19 | public function __construct(bool $caseSensitive = true) |
| 20 | 20 | { |
| 21 | - $isStringFct = function ($obj) { |
|
| 21 | + $isStringFct = function($obj) { |
|
| 22 | 22 | return is_string($obj); |
| 23 | 23 | }; |
| 24 | 24 | |
| 25 | 25 | if ($caseSensitive) { |
| 26 | - $isEquals = function ($obj1, $obj2) { |
|
| 26 | + $isEquals = function($obj1, $obj2) { |
|
| 27 | 27 | return (strcmp($obj1, $obj2) == 0); |
| 28 | 28 | }; |
| 29 | 29 | } else { |
| 30 | - $isEquals = function ($obj1, $obj2) { |
|
| 30 | + $isEquals = function($obj1, $obj2) { |
|
| 31 | 31 | return (strcasecmp($obj1, $obj2) == 0); |
| 32 | 32 | }; |
| 33 | 33 | } |
@@ -18,7 +18,7 @@ |
||
| 18 | 18 | */ |
| 19 | 19 | public function __construct() |
| 20 | 20 | { |
| 21 | - $isNumber = function ($obj) { |
|
| 21 | + $isNumber = function($obj) { |
|
| 22 | 22 | return is_numeric($obj); |
| 23 | 23 | }; |
| 24 | 24 | |