silverstripe-framework/ORM/Filters/EndsWithFilter.php
Damian Mooyman 8dd644d25d
API Namespace all classes
Namespace all templates
Move difflib and BBCodeParser2 to thirdparty
Remove deprecated API marked for removal in 4.0
2016-09-08 10:23:17 +12:00

20 lines
367 B
PHP

<?php
namespace SilverStripe\ORM\Filters;
/**
* Matches textual content with a substring match on a text fragment leading
* to the end of the string.
*
* <code>
* "abcdefg" => "defg" # true
* "abcdefg" => "abcd" # false
* </code>
*/
class EndsWithFilter extends PartialMatchFilter {
protected function getMatchPattern($value) {
return "%$value";
}
}