\Horde_SpellChecker_Aspell

A spellcheck driver for the aspell/ispell binary.

Summary

Methods
Properties
Constants
factory()
__construct()
setParams()
spellCheck()
No public properties found
SUGGEST_FAST
SUGGEST_NORMAL
SUGGEST_SLOW
_getWords()
_inLocalDictionary()
_cmd()
$_params
N/A
No private methods found
No private properties found
N/A

Constants

SUGGEST_FAST

SUGGEST_FAST

SUGGEST_NORMAL

SUGGEST_NORMAL

SUGGEST_SLOW

SUGGEST_SLOW

Properties

$_params

$_params : array

Configuration parameters.

Type

array

Methods

factory()

factory(string  $driver, array  $params = array()) : \Horde_SpellChecker

Attempts to return a concrete Horde_SpellChecker instance based on $driver.

Parameters

string $driver

The type of concrete subclass to return.

array $params

A hash containing any additional configuration or connection parameters a subclass might need.

Throws

\Horde_Exception

Returns

\Horde_SpellChecker

The newly created instance.

__construct()

__construct(array  $args = array()) 

Constructor.

Parameters

array $args

Additional arguments:

  • path: (string) Path to the aspell binary.

setParams()

setParams(array  $params) 

Set configuration parmeters.

Parameters

array $params

Parameters to set.

spellCheck()

spellCheck(string  $text) : array

Perform spellcheck.

Parameters

string $text

Text to spellcheck.

Returns

array —

TODO

_getWords()

_getWords(string  $text) : array

TODO

Parameters

string $text

TODO

Returns

array —

TODO

_inLocalDictionary()

_inLocalDictionary(string  $word) : boolean

Determine if a word exists in the local dictionary.

Parameters

string $word

The word to check.

Returns

boolean —

True if the word appears in the local dictionary.

_cmd()

_cmd() : string

Create the command line string.

Returns

string —

The command to run.