/**
  * Configures and loads Zend_Search_Lucene
  */
 public static function load()
 {
     if (!self::$loaded) {
         set_include_path(get_include_path() . PATH_SEPARATOR . realpath(dirname(__FILE__) . '/../vendor/'));
         // this is an ugly hack, but there's a bug somewhere with sfSimpleAutoload,
         // Zend_Search_Lucene, and PHP.
         require_once 'Zend/Search/Lucene.php';
         self::$loaded = true;
     }
 }
<?php

/**
 * This file is part of the sfLucene package.
 * (c) Carl Vondrick <*****@*****.**>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */
// load Zend_Search_Lucene
xfLuceneZendManager::load();
/**
 * The token filter to stem words.
 *
 * @package sfLucene
 * @subpackage Stemmer
 * @author Carl Vondrick
 */
final class xfLuceneStemmerTokenFilter extends Zend_Search_Lucene_Analysis_TokenFilter
{
    /**
     * The stemmer
     *
     * @var xfLuceneStemmer
     */
    private $stemmer;
    /**
     * Constructor to set stemmer.
     *
     * @param xfLuceneStemmer $stemmer
     */