PHP Class Sastrawi\Stemmer\Stemmer

Nazief & Adriani, CS Stemmer, ECS Stemmer, Improved ECS.
Inheritance: implements Sastrawi\Stemmer\StemmerInterface
Afficher le fichier Open project: sastrawi/sastrawi

Protected Properties

Свойство Type Description
$dictionary Sastrawi\Dictionary\DictionaryInterface The dictionary containing root words
$visitorProvider Sastrawi\Stemmer\Context\Visitor\VisitorProvider Visitor provider

Méthodes publiques

Méthode Description
__construct ( Sastrawi\Dictionary\DictionaryInterface $dictionary )
getDictionary ( ) : Sastrawi\Dictionary\DictionaryInterface
stem ( string $text ) : string Stem a text string to its common stem form.

Méthodes protégées

Méthode Description
isPlural ( string $word ) : boolean
stemPluralWord ( string $plural ) : string Stem a plural word to its common stem form.
stemSingularWord ( string $word ) : string Stem a singular word to its common stem form.
stemWord ( string $word ) : string Stem a word to its common stem form.

Method Details

__construct() public méthode

public __construct ( Sastrawi\Dictionary\DictionaryInterface $dictionary )
$dictionary Sastrawi\Dictionary\DictionaryInterface

getDictionary() public méthode

public getDictionary ( ) : Sastrawi\Dictionary\DictionaryInterface
Résultat Sastrawi\Dictionary\DictionaryInterface

isPlural() protected méthode

protected isPlural ( string $word ) : boolean
$word string
Résultat boolean

stem() public méthode

Stem a text string to its common stem form.
public stem ( string $text ) : string
$text string the text string to stem, e.g : memberdayakan pembangunan
Résultat string common stem form, e.g : daya bangun

stemPluralWord() protected méthode

Asian J. (2007) “Effective Techniques for Indonesian Text Retrieval” page 76-77.
protected stemPluralWord ( string $plural ) : string
$plural string the word to stem, e.g : bersama-sama
Résultat string common stem form, e.g : sama

stemSingularWord() protected méthode

Stem a singular word to its common stem form.
protected stemSingularWord ( string $word ) : string
$word string the word to stem, e.g : mengalahkan
Résultat string common stem form, e.g : kalah

stemWord() protected méthode

Stem a word to its common stem form.
protected stemWord ( string $word ) : string
$word string the word to stem, e.g : memberdayakan
Résultat string common stem form, e.g : daya

Property Details

$dictionary protected_oe property

The dictionary containing root words
protected DictionaryInterface,Sastrawi\Dictionary $dictionary
Résultat Sastrawi\Dictionary\DictionaryInterface

$visitorProvider protected_oe property

Visitor provider
protected VisitorProvider,Sastrawi\Stemmer\Context\Visitor $visitorProvider
Résultat Sastrawi\Stemmer\Context\Visitor\VisitorProvider