2008-08-09 08:40:50 +02:00
|
|
|
<?php
|
|
|
|
/**
|
2012-04-12 08:02:46 +02:00
|
|
|
* @package framework
|
2008-08-09 08:40:50 +02:00
|
|
|
* @subpackage search
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Matches textual content with a substring match from the beginning
|
|
|
|
* of the string.
|
2014-08-15 08:53:05 +02:00
|
|
|
*
|
2008-08-09 08:40:50 +02:00
|
|
|
* <code>
|
|
|
|
* "abcdefg" => "defg" # false
|
|
|
|
* "abcdefg" => "abcd" # true
|
|
|
|
* </code>
|
2014-08-15 08:53:05 +02:00
|
|
|
*
|
2012-04-12 08:02:46 +02:00
|
|
|
* @package framework
|
2008-08-09 08:40:50 +02:00
|
|
|
* @subpackage search
|
|
|
|
*/
|
2013-06-21 00:32:08 +02:00
|
|
|
class StartsWithFilter extends PartialMatchFilter {
|
2012-12-10 23:35:04 +01:00
|
|
|
|
2013-06-21 00:32:08 +02:00
|
|
|
protected function getMatchPattern($value) {
|
|
|
|
return "$value%";
|
2008-08-11 02:03:57 +02:00
|
|
|
}
|
2008-08-09 08:40:50 +02:00
|
|
|
}
|