Joomla CMS  3.9.25 (avec JPlatform 13.1 inclus)
Documentation des API du CMS Joomla en version 3.9.25 et du framework Joomla Platform intégré
Référence de la classe Porteren
+ Graphe d'héritage de Porteren:

Fonctions membres publiques

 stem ($token, $lang)
 
- Fonctions membres publiques hérités de LanguageStemmer
 stem ($token, $lang)
 

Fonctions membres privées statiques

static _step1ab ($word)
 
static _step1c ($word)
 
static _step2 ($word)
 
static _step3 ($word)
 
static _step4 ($word)
 
static _step5 ($word)
 
static _replace (&$str, $check, $repl, $m=null)
 
static _m ($str)
 
static _doubleConsonant ($str)
 
static _cvc ($str)
 

Attributs privés statiques

static $_regex_consonant = '(?:[bcdfghjklmnpqrstvwxz]|(?<=[aeiou])y|^y)'
 
static $_regex_vowel = '(?:[aeiou]|(?<![aeiou])y)'
 

Membres hérités additionnels

- Fonctions membres publiques statiques hérités de LanguageStemmer
static getInstance ($adapter)
 
- Attributs protégés hérités de LanguageStemmer
 $cache = array()
 
- Attributs protégés statiques hérités de LanguageStemmer
static $instances = array()
 

Description détaillée

Porter English stemmer class.

This class was adapted from one written by Richard Heyes. See copyright and link information above.

Depuis
3.0.0
Obsolète:
4.0 Use wamania/php-stemmer

Documentation des fonctions membres

◆ _cvc()

static _cvc (   $str)
staticprivate

Checks for ending CVC sequence where second C is not W, X or Y

Paramètres
string$strString to check
Renvoie
boolean Result
Depuis
3.0.0

◆ _doubleConsonant()

static _doubleConsonant (   $str)
staticprivate

Returns true/false as to whether the given string contains two of the same consonant next to each other at the end of the string.

Paramètres
string$strString to check
Renvoie
boolean Result
Depuis
3.0.0

◆ _m()

static _m (   $str)
staticprivate

m() measures the number of consonant sequences in $str. if c is a consonant sequence and v a vowel sequence, and <..> indicates arbitrary presence,

<v> gives 0 vc<v> gives 1 vcvc<v> gives 2 vcvcvc<v> gives 3

Paramètres
string$strThe string to return the m count for
Renvoie
integer The m count
Depuis
3.0.0

◆ _replace()

static _replace ( $str,
  $check,
  $repl,
  $m = null 
)
staticprivate

Replaces the first string with the second, at the end of the string. If third arg is given, then the preceding string must match that m count at least.

Paramètres
string&$strString to check
string$checkEnding to check for
string$replReplacement string
integer$mOptional minimum number of m() to meet
Renvoie
boolean Whether the $check string was at the end of the $str string. True does not necessarily mean that it was replaced.
Depuis
3.0.0

Références $check.

◆ _step1ab()

static _step1ab (   $word)
staticprivate

Step 1

Paramètres
string$wordThe token to stem.
Renvoie
string
Depuis
3.0.0

Références elseif.

◆ _step1c()

static _step1c (   $word)
staticprivate

Step 1c

Paramètres
string$wordThe token to stem.
Renvoie
string
Depuis
3.0.0

◆ _step2()

static _step2 (   $word)
staticprivate

Step 2

Paramètres
string$wordThe token to stem.
Renvoie
string
Depuis
3.0.0

◆ _step3()

static _step3 (   $word)
staticprivate

Step 3

Paramètres
string$wordThe token to stem.
Renvoie
string
Depuis
3.0.0

◆ _step4()

static _step4 (   $word)
staticprivate

Step 4

Paramètres
string$wordThe token to stem.
Renvoie
string
Depuis
3.0.0

◆ _step5()

static _step5 (   $word)
staticprivate

Step 5

Paramètres
string$wordThe token to stem.
Renvoie
string
Depuis
3.0.0

Références elseif.

◆ stem()

stem (   $token,
  $lang 
)

Method to stem a token and return the root.

Paramètres
string$tokenThe token to stem.
string$langThe language of the token.
Renvoie
string The root token.
Depuis
3.0.0

Références Language\$lang.

Documentation des champs

◆ $_regex_consonant

$_regex_consonant = '(?:[bcdfghjklmnpqrstvwxz]|(?<=[aeiou])y|^y)'
staticprivate

◆ $_regex_vowel

$_regex_vowel = '(?:[aeiou]|(?<![aeiou])y)'
staticprivate

La documentation de cette classe a été générée à partir du fichier suivant :