| @@ 43-57 (lines=15) @@ | ||
| 40 | /** |
|
| 41 | * {@inheritdoc} |
|
| 42 | */ |
|
| 43 | public function containsAll($elements) { |
|
| 44 | $elements = $this->collectionToArray($elements); |
|
| 45 | ||
| 46 | $result = TRUE; |
|
| 47 | ||
| 48 | foreach($elements as $item) { |
|
| 49 | if($this->contains($item) === FALSE) { |
|
| 50 | $result = FALSE; |
|
| 51 | ||
| 52 | break; |
|
| 53 | } |
|
| 54 | } |
|
| 55 | ||
| 56 | return $result; |
|
| 57 | } |
|
| 58 | ||
| 59 | /** |
|
| 60 | * {@inheritdoc} |
|
| @@ 129-141 (lines=13) @@ | ||
| 126 | /** |
|
| 127 | * {@inheritdoc} |
|
| 128 | */ |
|
| 129 | public function removeAll($elements) { |
|
| 130 | $elements = $this->collectionToArray($elements); |
|
| 131 | ||
| 132 | $result = FALSE; |
|
| 133 | ||
| 134 | foreach($elements as $item) { |
|
| 135 | if($this->remove($item) === TRUE) { |
|
| 136 | $result = TRUE; |
|
| 137 | } |
|
| 138 | } |
|
| 139 | ||
| 140 | return $result; |
|
| 141 | } |
|
| 142 | ||
| 143 | /** |
|
| 144 | * {@inheritdoc} |
|
| @@ 105-119 (lines=15) @@ | ||
| 102 | /** |
|
| 103 | * {@inheritDoc} |
|
| 104 | */ |
|
| 105 | public function containsAll($elements) { |
|
| 106 | $elements = $this->collectionToArray($elements); |
|
| 107 | ||
| 108 | $result = TRUE; |
|
| 109 | ||
| 110 | foreach($elements as $item) { |
|
| 111 | if($this->contains($item) === FALSE) { |
|
| 112 | $result = FALSE; |
|
| 113 | ||
| 114 | break; |
|
| 115 | } |
|
| 116 | } |
|
| 117 | ||
| 118 | return $result; |
|
| 119 | } |
|
| 120 | ||
| 121 | /** |
|
| 122 | * {@inheritDoc} |
|