Releases: mcustiel/php-simple-regex
Releases · mcustiel/php-simple-regex
Added method to get submatch or default value in Match
- Added getSubMatchOrDefaultAt in Match.
- Removed version field from composer.
- Changed the way php-simple-regex is checking for external regex generators.
- Improved exception message for No submatch found.
Fixed wrong value in composer.json
v1.0.2 Fix in version
Fixed missing value in composer.json
- BugFix: Version missing in composer.json.
First functional version
- Added Executor class with methods:
- MatchResult getAllMatches(string $pattern, string $subject, integer $offset = 0)
- Match getOneMatch(string $pattern, string $subject, integer $offset = 0)
- boolean match(string $pattern, string $subject, integer $offset = 0)
- ReplaceResult replaceAndCount(string $pattern, string $replacement, mixed $subject, integer $limit = -1)
- mixed replace(string $pattern, string $replacement, mixed $subject, integer $limit = -1)
- mixed replaceCallback(string $pattern, callable $callback, mixed $subject, integer $limit = -1)
- ReplaceResult replaceCallbackAndCount(string $pattern, callable $callback, mixed $subject, integer $limit = -1)
- Added Match, MatchResult and ReplaceResult objects.
- Support for Flux and VerbalExpressions
- Errors are thrown as exceptions and not displayed.
- Unit tests added.