Suffix anchors
end
The end
method adds an end anchor. Matches the position immediately after the last character in the context.
Ensures that the specified pattern occurs just before the end of the line.
use Rudashi\Regex;
$pattern = Regex::build()->end();
// /$/
endOfLine
The endOfLine
method is equivalent to the end
method.
use Rudashi\Regex;
$pattern = Regex::build()->endOfLine();
// /$/