* @author Timo Hund */ class Suggestion { /** * @var string */ protected $suggestion = ''; /** * @var string */ protected $missSpelled = ''; /** * @var int */ protected $numFound = 1; /** * @var int */ protected $startOffset = 0; /** * @var int */ protected $endOffset = 0; /** * @param string $suggestion the suggested term * @param string $missSpelled the misspelled original term * @param int $numFound * @param int $startOffset * @param int $endOffset */ public function __construct($suggestion = '', $missSpelled = '', $numFound = 1, $startOffset = 0, $endOffset = 0) { $this->suggestion = $suggestion; $this->missSpelled = $missSpelled; $this->numFound = $numFound; $this->startOffset = $startOffset; $this->endOffset = $endOffset; } /** * @return int */ public function getEndOffset() { return $this->endOffset; } /** * @return int */ public function getNumFound() { return $this->numFound; } /** * @return int */ public function getStartOffset() { return $this->startOffset; } /** * @return string */ public function getSuggestion() { return $this->suggestion; } /** * @return string */ public function getMissSpelled() { return $this->missSpelled; } }