@@ -28,7 +28,7 @@ discard block |
||
| 28 | 28 | * @param int $index |
| 29 | 29 | */ |
| 30 | 30 | public function offsetExists($index): bool { |
| 31 | - return $index >= 0 AND $index < count($this->items); |
|
| 31 | + return $index >= 0 and $index < count($this->items); |
|
| 32 | 32 | } |
| 33 | 33 | |
| 34 | 34 | /** |
@@ -36,7 +36,7 @@ discard block |
||
| 36 | 36 | * @throws \OutOfRangeException |
| 37 | 37 | */ |
| 38 | 38 | public function offsetGet($index) { |
| 39 | - if($index < 0 OR $index >= count($this->items)) { |
|
| 39 | + if($index < 0 or $index >= count($this->items)) { |
|
| 40 | 40 | throw new \OutOfRangeException("Offset invalid or out of range."); |
| 41 | 41 | } |
| 42 | 42 | return $this->items[$index]; |
@@ -68,11 +68,11 @@ discard block |
||
| 68 | 68 | throw new \InvalidArgumentException("Argument must be of $this->class type."); |
| 69 | 69 | } elseif(!$this->checkUniqueness($item)) { |
| 70 | 70 | $property = $this->uniqueProperty; |
| 71 | - throw new \RuntimeException("Duplicate $property {$item->$property}."); |
|
| 71 | + throw new \RuntimeException("duplicate $property {$item->$property}."); |
|
| 72 | 72 | } |
| 73 | 73 | if($index === NULL) { |
| 74 | 74 | $this->items[] = & $item; |
| 75 | - } elseif($index < 0 OR $index >= count($this->items)) { |
|
| 75 | + } elseif($index < 0 or $index >= count($this->items)) { |
|
| 76 | 76 | throw new \OutOfRangeException("Offset invalid or out of range."); |
| 77 | 77 | } else { |
| 78 | 78 | $this->items[$index] = & $item; |
@@ -84,7 +84,7 @@ discard block |
||
| 84 | 84 | * @throws \OutOfRangeException |
| 85 | 85 | */ |
| 86 | 86 | public function offsetUnset($index): void { |
| 87 | - if($index < 0 OR $index >= count($this->items)) { |
|
| 87 | + if($index < 0 or $index >= count($this->items)) { |
|
| 88 | 88 | throw new \OutOfRangeException("Offset invalid or out of range."); |
| 89 | 89 | } |
| 90 | 90 | array_splice($this->items, $index, 1); |
@@ -24,7 +24,7 @@ discard block |
||
| 24 | 24 | } |
| 25 | 25 | |
| 26 | 26 | public static function isInInterval(int $number, string $interval): bool { |
| 27 | - if(is_null(static::findInterval($interval)) OR $interval !== static::findInterval($interval)) { |
|
| 27 | + if(is_null(static::findInterval($interval)) or $interval !== static::findInterval($interval)) { |
|
| 28 | 28 | return false; |
| 29 | 29 | } |
| 30 | 30 | if(Strings::startsWith($interval, "{")) { |
@@ -42,9 +42,9 @@ discard block |
||
| 42 | 42 | return false; |
| 43 | 43 | } elseif($number > $limit2) { |
| 44 | 44 | return false; |
| 45 | - } elseif($number === $limit1 AND $start === "]") { |
|
| 45 | + } elseif($number === $limit1 and $start === "]") { |
|
| 46 | 46 | return false; |
| 47 | - } elseif($number === $limit2 AND $end === "[") { |
|
| 47 | + } elseif($number === $limit2 and $end === "[") { |
|
| 48 | 48 | return false; |
| 49 | 49 | } |
| 50 | 50 | return true; |