|
@@ 1551-1555 (lines=5) @@
|
| 1548 |
|
return static::create($replacement, $this->encoding); |
| 1549 |
|
} |
| 1550 |
|
|
| 1551 |
|
if ($caseSensitive) { |
| 1552 |
|
$return = UTF8::str_replace($search, $replacement, $this->str); |
| 1553 |
|
} else { |
| 1554 |
|
$return = UTF8::str_ireplace($search, $replacement, $this->str); |
| 1555 |
|
} |
| 1556 |
|
|
| 1557 |
|
return static::create($return, $this->encoding); |
| 1558 |
|
} |
|
@@ 1571-1575 (lines=5) @@
|
| 1568 |
|
*/ |
| 1569 |
|
public function replaceAll(array $search, $replacement, bool $caseSensitive = true): self |
| 1570 |
|
{ |
| 1571 |
|
if ($caseSensitive) { |
| 1572 |
|
$return = UTF8::str_replace($search, $replacement, $this->str); |
| 1573 |
|
} else { |
| 1574 |
|
$return = UTF8::str_ireplace($search, $replacement, $this->str); |
| 1575 |
|
} |
| 1576 |
|
|
| 1577 |
|
return static::create($return, $this->encoding); |
| 1578 |
|
} |