Search_Stemmer_Ru
extends Search_Stemmer
in package
Implementation of the Porter Stemmer algorithm.
http://snowball.tartarus.org/algorithms/russian/stemmer.html
Tags
Table of Contents
Properties
- $instance : array<string|int, mixed>
- The singleton instances.
- $_cache : array<string|int, mixed>
- Cache
- $_config : array<string|int, mixed>
- Config
- $_useCache : bool
- Разрешает кэширование
Methods
- __construct() : mixed
- clearCache() : self
- Clear cache
- instance() : mixed
- Get instance of class
- stem() : string
- Определение основы слова
- _applyPattern() : bool
- Метод проверяет строку на наличие вхождений подстрок заданных регулярным выражением
- _getDriverName() : string
- Get full driver name
Properties
$instance
The singleton instances.
public
static array<string|int, mixed>
$instance
= array()
$_cache
Cache
protected
array<string|int, mixed>
$_cache
= array()
Tags
$_config
Config
protected
array<string|int, mixed>
$_config
= array()
Tags
$_useCache
Разрешает кэширование
protected
bool
$_useCache
= \TRUE
Tags
Methods
__construct()
public
__construct() : mixed
clearCache()
Clear cache
public
clearCache() : self
Return values
selfinstance()
Get instance of class
public
static instance(string $name) : mixed
Parameters
- $name : string
-
class name
stem()
Определение основы слова
public
stem(string $word) : string
Parameters
- $word : string
-
слово
Return values
string —основа слова
_applyPattern()
Метод проверяет строку на наличие вхождений подстрок заданных регулярным выражением
protected
_applyPattern(string &$text, string $pattern[, string $replace = '' ]) : bool
Parameters
- $text : string
-
обрабатываемая строка
- $pattern : string
-
регулярное выражение
- $replace : string = ''
-
текст замены
Tags
Return values
bool —была замена
_getDriverName()
Get full driver name
protected
static _getDriverName(string $driver) : string
Parameters
- $driver : string
-
driver name