Changeset 7108
- Timestamp:
- 01/20/08 08:44:42 (2 years ago)
- Files:
-
- plugins/sfLucenePlugin/branches/1.1 (modified) (1 prop)
- plugins/sfLucenePlugin/branches/1.1/CHANGELOG (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/LICENSE (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/README (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/VERSION (deleted)
- plugins/sfLucenePlugin/branches/1.1/data/skeleton/module/actions/actions.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/data/skeleton/module/actions/components.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/addon/Zend/sfLuceneDirectoryStorage.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/addon/Zend/sfLuceneFileStorage.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/addon/Zend/sfLuceneLowerCaseFilter.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/behavior/sfLucenePropelBehavior.class.php (modified) (8 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/behavior/sfLucenePropelInitializer.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/category/sfLuceneCategories.class.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/category/sfLuceneCategory.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/config/sfLuceneModuleConfigHandler.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/config/sfLuceneProjectConfigHandler.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/event/sfLuceneEventConnector.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/event/sfLuceneEventConnectorLogger.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneException.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneHighlighterException.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneHighlighterXMLException.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneIndexerException.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneResultsException.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/filter/browser/sfLuceneCacheFilter.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/filter/browser/sfLuceneExecutionFilter.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/filter/browser/sfLuceneRenderingFilter.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/filter/sfLuceneHighlightFilter.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneAdvancedForm.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneAdvancedFormBase.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneForm.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneSimpleForm.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneSimpleFormBase.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/helper/sfLuceneHelper.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterKeyword.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterKeywordNamed.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterKeywordNamedInsensitive.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterKeywordZend.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterToken.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarker.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarkerDry.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarkerHarness.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarkerSprint.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarkerUppercase.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighter.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterHTML.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterHTMLPart.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterString.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterXHTML.class.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterXHTMLPart.class.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterXML.class.php (modified) (6 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneActionIndexer.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneActionIndexerHandler.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneIndexer.class.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneIndexerFactory.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneIndexerHandler.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneModelIndexer.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneModelIndexerHandler.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLucenePropelIndexer.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLucenePropelIndexerHandler.class.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/lib/results/sfLuceneActionResult.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/results/sfLuceneModelResult.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/results/sfLucenePager.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/results/sfLuceneResult.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/results/sfLuceneResults.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/sfLucene.class.php (modified) (12 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/storage/sfLuceneStorage.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/storage/sfLuceneStorageBlackhole.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/storage/sfLuceneStorageFilesystem.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneAboutTask.class.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneBaseTask.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneCleanupTask.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneInitializeModuleTask.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneInitializeTask.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneOptimizeTask.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneRebuildTask.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/util/sfLuceneBrowser.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/util/sfLuceneCriteria.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/util/sfLuceneToolkit.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/widget/sfLuceneWidgetFormatter.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/widget/sfLuceneWidgetFormatterAdvanced.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/lib/widget/sfLuceneWidgetFormatterSimple.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/actions/actions.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/actions/components.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/lib/BasesfLuceneActions.class.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/lib/BasesfLuceneComponents.class.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_actionResult.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_categories.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_controls.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_modelResult.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_pagerNavigation.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_publicControls.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/advancedControls.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/searchControls.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/searchNoResults.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/searchResults.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/package.xml (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/test (modified) (1 prop)
- plugins/sfLucenePlugin/branches/1.1/test/bin/AllFakeModels.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/test/bin/limeade_lucene.php (copied) (copied from plugins/sfLucenePlugin/trunk/test/bin/limeade_lucene.php)
- plugins/sfLucenePlugin/branches/1.1/test/bootstrap/unit.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/coverage.php (modified) (1 diff)
- plugins/sfLucenePlugin/branches/1.1/test/launch.php (deleted)
- plugins/sfLucenePlugin/branches/1.1/test/prove.php (copied) (copied from plugins/sfLucenePlugin/trunk/test/prove.php)
- plugins/sfLucenePlugin/branches/1.1/test/unit/addon/Zend/sfLuceneDirectoryStorageTest.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/addon/Zend/sfLuceneFileStorageTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/addon/Zend/sfLuceneLowerCaseFilterTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/behavior/sfLucenePropelBehaviorTest.php (modified) (4 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/behavior/sfLucenePropelInitializerTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/category/sfLuceneCategoriesTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/category/sfLuceneCategoryTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/config/sfLuceneModuleConfigHandlerTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/config/sfLuceneProjectConfigHandlerTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/event/sfLuceneEventConnectorLoggerTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/event/sfLuceneEventConnectorTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/filter/browser/sfLuceneCacheFilterTest.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/filter/browser/sfLuceneExecutionFilterTest.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/filter/browser/sfLuceneRenderingFilterTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/filter/sfLuceneHighlightFilterTest.php (modified) (4 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/form/sfLuceneAdvancedFormTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/form/sfLuceneFormTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/form/sfLuceneSimpleFormTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/helper/sfLuceneHelperTest.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/keyword/sfLuceneHighlighterKeywordNamedInsensitiveTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/keyword/sfLuceneHighlighterKeywordNamedTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/keyword/sfLuceneHighlighterKeywordZendTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/keyword/sfLuceneHighlighterTokenTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/marker/sfLuceneHighlighterMarkerDryTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/marker/sfLuceneHighlighterMarkerHarnessTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/marker/sfLuceneHighlighterMarkerSprintTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/marker/sfLuceneHighlighterMarkerUppercaseTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterHTMLPartTest.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterHTMLTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterStringTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterXHTMLPartTest.php (modified) (4 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterXHTMLTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterXMLTest.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/indexer/sfLuceneIndexerFactoryTest.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/indexer/sfLucenePropelIndexerHandlerTest.php (modified) (3 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/indexer/sfLucenePropelIndexerTest.php (modified) (9 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/results/sfLuceneActionResultTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/results/sfLuceneModelResultTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/results/sfLucenePagerTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/results/sfLuceneResultTest.php (modified) (6 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/results/sfLuceneResultsTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/sfLuceneEraseIndexTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/sfLuceneLazyLoadingTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/sfLuceneTest.php (modified) (13 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/storage/sfLuceneStorageBlackholeTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/storage/sfLuceneStorageFilesystemTest.php (modified) (4 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/util/sfLuceneCriteriaTest.php (modified) (2 diffs)
- plugins/sfLucenePlugin/branches/1.1/test/unit/util/sfLuceneToolkitTest.php (modified) (4 diffs)
- plugins/sfLucenePlugin/branches/1.1/web/css/search.css (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
plugins/sfLucenePlugin/branches/1.1
- Property svn:externals deleted
plugins/sfLucenePlugin/branches/1.1/CHANGELOG
r6883 r7108 20 20 * BC: sfLuceneCriteria constructor now requires sfLucene instance 21 21 * Refactored highlighting system 22 * Added ability to lock the Propel behavior. 22 23 23 24 Version 0.1.1 Beta plugins/sfLucenePlugin/branches/1.1/LICENSE
r6247 r7108 3 3 -------------------------------------------------------------------------------- 4 4 5 Copyright (c) 2007 Carl Vondrick5 Copyright (c) 2007 - 2008 Carl Vondrick 6 6 7 7 Permission is hereby granted, free of charge, to any person obtaining a copy of plugins/sfLucenePlugin/branches/1.1/README
r6890 r7108 154 154 after the class declaration. So, for a blog, you would open project/lib/model/BlogPost.php and append the above, replacing "!MyModel" with "!BlogPost". 155 155 156 If you wish to disable the Propel behavior so that no indexing can occur, you can simply do: 157 {{{ 158 sfLucenePropelBehavior::setLock(true); // disables Propel behavior, no indexing 159 sfLucenePropelBehavior::setLock(false); // enables Propel behavior, does index 160 }}} 161 162 By default, the behavior is not locked so indexing does occur. 163 156 164 == Advanced Model Settings == 157 165 You can configure the model even more. If the peer does not follow symfony's naming conventions, you can specify a new one with in the project level search.yml: plugins/sfLucenePlugin/branches/1.1/data/skeleton/module/actions/actions.class.php
r6395 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Module 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id: actions.class.php 6247 2007-12-01 03:25:13Z Carl.Vondrick $ 17 17 */ plugins/sfLucenePlugin/branches/1.1/data/skeleton/module/actions/components.class.php
r6395 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 14 14 * @package sfLucenePlugin 15 15 * @subpackage Module 16 * @author Carl Vondrick <carl v@carlsoft.net>16 * @author Carl Vondrick <carl@carlsoft.net> 17 17 * @version SVN: $Id: components.class.php 6247 2007-12-01 03:25:13Z Carl.Vondrick $ 18 18 */ plugins/sfLucenePlugin/branches/1.1/lib/addon/Zend/sfLuceneDirectoryStorage.class.php
r6680 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/addon/Zend/sfLuceneFileStorage.class.php
r6680 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/addon/Zend/sfLuceneLowerCaseFilter.class.php
r6681 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/behavior/sfLucenePropelBehavior.class.php
r6733 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 12 12 * @package sfLucenePlugin 13 13 * @subpackage Behavior 14 * @author Carl Vondrick <carl v@carlsoft.net>14 * @author Carl Vondrick <carl@carlsoft.net> 15 15 * @version SVN: $Id$ 16 16 */ … … 26 26 */ 27 27 protected $deleteQueue = array(); 28 29 /** 30 * If true, then nothing can be added to the queues. 31 */ 32 static protected $locked = false; 28 33 29 34 /** … … 36 41 public function preSave($node) 37 42 { 43 if (self::$locked) 44 { 45 return; 46 } 47 38 48 if ($node->isModified() || $node->isNew()) 39 49 { … … 77 87 public function preDelete($node) 78 88 { 89 if (self::$locked) 90 { 91 return; 92 } 93 79 94 if (!$node->isNew()) 80 95 { … … 126 141 foreach ($this->getSearchInstances($node) as $instance) 127 142 { 128 $instance->getIndexer ()->getModel($node)->delete();143 $instance->getIndexerFactory()->getModel($node)->delete(); 129 144 } 130 145 } … … 137 152 foreach ($this->getSearchInstances($node) as $instance) 138 153 { 139 $instance->getIndexer ()->getModel($node)->insert();154 $instance->getIndexerFactory()->getModel($node)->insert(); 140 155 } 141 156 } … … 192 207 return sfLucenePropelInitializer::getInstance(); 193 208 } 209 210 /** 211 * Locks the Propel behavior, so nothing can be queued. 212 * @param bool $to If true, the behavior is locked. If false, the behavior is unlocked. 213 */ 214 static public function setLock($to) 215 { 216 self::$locked = (bool) $to; 217 } 194 218 } plugins/sfLucenePlugin/branches/1.1/lib/behavior/sfLucenePropelInitializer.class.php
r6733 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 12 12 * @package sfLucenePlugin 13 13 * @subpackage Behavior 14 * @author Carl Vondrick <carl v@carlsoft.net>14 * @author Carl Vondrick <carl@carlsoft.net> 15 15 * @version SVN: $Id$ 16 16 */ plugins/sfLucenePlugin/branches/1.1/lib/category/sfLuceneCategories.class.php
r6489 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 12 12 * @package sfLucenePlugin 13 13 * @subpackage Category 14 * @author Carl Vondrick <carl v@carlsoft.net>14 * @author Carl Vondrick <carl@carlsoft.net> 15 15 * @version SVN: $Id$ 16 16 */ … … 58 58 59 59 $this->load(); 60 } 61 62 public function __destruct() 63 { 64 $this->save(); 60 65 } 61 66 plugins/sfLucenePlugin/branches/1.1/lib/category/sfLuceneCategory.class.php
r6525 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 12 12 * @package sfLucenePlugin 13 13 * @subpackage Category 14 * @author Carl Vondrick <carl v@carlsoft.net>14 * @author Carl Vondrick <carl@carlsoft.net> 15 15 * @version SVN: $Id$ 16 16 */ plugins/sfLucenePlugin/branches/1.1/lib/config/sfLuceneModuleConfigHandler.class.php
r6696 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 11 11 * @package sfLucenePlugin 12 12 * @subpackage Config 13 * @author Carl Vondrick <carl v@carlsoft.net>13 * @author Carl Vondrick <carl@carlsoft.net> 14 14 * @version SVN: $Id$ 15 15 */ plugins/sfLucenePlugin/branches/1.1/lib/config/sfLuceneProjectConfigHandler.class.php
r6705 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 11 11 * @package sfLucenePlugin 12 12 * @subpackage Config 13 * @author Carl Vondrick <carl v@carlsoft.net>13 * @author Carl Vondrick <carl@carlsoft.net> 14 14 * @version SVN: $Id$ 15 15 */ plugins/sfLucenePlugin/branches/1.1/lib/event/sfLuceneEventConnector.class.php
r6792 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 14 14 * @package sfLucenePlugin 15 15 * @subpackage Event 16 * @author Carl Vondrick <carl v@carlsoft.net>16 * @author Carl Vondrick <carl@carlsoft.net> 17 17 * @version SVN: $Id$ 18 18 */ plugins/sfLucenePlugin/branches/1.1/lib/event/sfLuceneEventConnectorLogger.class.php
r6792 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 14 14 * @package sfLucenePlugin 15 15 * @subpackage Event 16 * @author Carl Vondrick <carl v@carlsoft.net>16 * @author Carl Vondrick <carl@carlsoft.net> 17 17 * @version SVN: $Id$ 18 18 */ plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneException.class.php
r6247 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 10 10 * @package sfLucenePlugin 11 11 * @subpackage Exception 12 * @author Carl Vondrick <carl v@carlsoft.net>12 * @author Carl Vondrick <carl@carlsoft.net> 13 13 * @version SVN: $Id$ 14 14 */ plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneHighlighterException.class.php
r6247 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 10 10 * @package sfLucenePlugin 11 11 * @subpackage Exception 12 * @author Carl Vondrick <carl v@carlsoft.net>12 * @author Carl Vondrick <carl@carlsoft.net> 13 13 * @version SVN: $Id$ 14 14 */ plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneHighlighterXMLException.class.php
r6911 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 10 10 * @package sfLucenePlugin 11 11 * @subpackage Exception 12 * @author Carl Vondrick <carl v@carlsoft.net>12 * @author Carl Vondrick <carl@carlsoft.net> 13 13 * @version SVN: $Id$ 14 14 */ plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneIndexerException.class.php
r6247 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 10 10 * @package sfLucenePlugin 11 11 * @subpackage Exception 12 * @author Carl Vondrick <carl v@carlsoft.net>12 * @author Carl Vondrick <carl@carlsoft.net> 13 13 * @version SVN: $Id$ 14 14 */ plugins/sfLucenePlugin/branches/1.1/lib/exception/sfLuceneResultsException.class.php
r6247 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 10 10 * @package sfLucenePlugin 11 11 * @subpackage Exception 12 * @author Carl Vondrick <carl v@carlsoft.net>12 * @author Carl Vondrick <carl@carlsoft.net> 13 13 * @version SVN: $Id$ 14 14 */ plugins/sfLucenePlugin/branches/1.1/lib/filter/browser/sfLuceneCacheFilter.class.php
r6247 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/filter/browser/sfLuceneExecutionFilter.class.php
r6671 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/filter/browser/sfLuceneRenderingFilter.class.php
r6247 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/filter/sfLuceneHighlightFilter.class.php
r6911 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 16 16 * @package sfLucenePlugin 17 17 * @subpackage Filter 18 * @author Carl Vondrick <carl v@carlsoft.net>18 * @author Carl Vondrick <carl@carlsoft.net> 19 19 * @version SVN: $Id$ 20 20 */ plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneAdvancedForm.class.php
r6525 r7108 2 2 /* 3 3 * This file is part of the sfLucenePLugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 * @package sfLucenePlugin 18 18 * @subpackage Form 19 * @author Carl Vondrick <carl v@carlsoft.net>19 * @author Carl Vondrick <carl@carlsoft.net> 20 20 * @version SVN: $Id$ 21 21 */ plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneAdvancedFormBase.class.php
r6816 r7108 2 2 /* 3 3 * This file is part of the sfLucenePLugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 * @package sfLucenePlugin 18 18 * @subpackage Form 19 * @author Carl Vondrick <carl v@carlsoft.net>19 * @author Carl Vondrick <carl@carlsoft.net> 20 20 * @version SVN: $Id$ 21 21 */ plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneForm.class.php
r6816 r7108 2 2 /* 3 3 * This file is part of the sfLucenePLugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 14 14 * @package sfLucenePlugin 15 15 * @subpackage Form 16 * @author Carl Vondrick <carl v@carlsoft.net>16 * @author Carl Vondrick <carl@carlsoft.net> 17 17 * @version SVN: $Id$ 18 18 */ plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneSimpleForm.class.php
r6525 r7108 2 2 /* 3 3 * This file is part of the sfLucenePLugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 * @package sfLucenePlugin 18 18 * @subpackage Form 19 * @author Carl Vondrick <carl v@carlsoft.net>19 * @author Carl Vondrick <carl@carlsoft.net> 20 20 * @version SVN: $Id$ 21 21 */ plugins/sfLucenePlugin/branches/1.1/lib/form/sfLuceneSimpleFormBase.class.php
r6816 r7108 2 2 /* 3 3 * This file is part of the sfLucenePLugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 * @package sfLucenePlugin 18 18 * @subpackage Form 19 * @author Carl Vondrick <carl v@carlsoft.net>19 * @author Carl Vondrick <carl@carlsoft.net> 20 20 * @version SVN: $Id$ 21 21 */ plugins/sfLucenePlugin/branches/1.1/lib/helper/sfLuceneHelper.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 11 11 * @package sfLucenePlugin 12 12 * @subpackage Helper 13 * @author Carl Vondrick <carl v@carlsoft.net>13 * @author Carl Vondrick <carl@carlsoft.net> 14 14 * @version SVN: $Id$ 15 15 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterKeyword.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterKeywordNamed.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterKeywordNamedInsensitive.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterKeywordZend.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 14 14 * @package sfLucenePlugin 15 15 * @subpackage Highlighter 16 * @author Carl Vondrick <carl v@carlsoft.net>16 * @author Carl Vondrick <carl@carlsoft.net> 17 17 * @version SVN: $Id$ 18 18 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/keyword/sfLuceneHighlighterToken.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarker.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarkerDry.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarkerHarness.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarkerSprint.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/marker/sfLuceneHighlighterMarkerUppercase.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighter.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 15 15 * @package sfLucenePlugin 16 16 * @subpackage Highlighter 17 * @author Carl Vondrick <carl v@carlsoft.net>17 * @author Carl Vondrick <carl@carlsoft.net> 18 18 * @version SVN: $Id$ 19 19 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterHTML.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterHTMLPart.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterString.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterXHTML.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ … … 42 42 } 43 43 44 protected function doHighlightNode(DOMNode $node)44 protected function ignoreNode(DOMNode $node) 45 45 { 46 if ( $this->ignoreNode($node))46 if (!parent::ignoreNode($node)) 47 47 { 48 return ;48 return ($node->nodeName == 'script' || $node->nodeName == 'style' || $node->nodeName == 'textarea'); 49 49 } 50 50 51 parent::doHighlightNode($node); 52 } 53 54 protected function ignoreNode(DOMNode $node) 55 { 56 return ($node->nodeName == 'script' || $node->nodeName == 'style' || $node->nodeName == 'textarea'); 51 return true; 57 52 } 58 53 } plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterXHTMLPart.class.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ … … 21 21 { 22 22 // convert the data to a full document and we'll remove this part later 23 $this->data = '< html><body>' . $this->data . '</body></html>';23 $this->data = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/2000/REC-xhtml1-200000126/DTD/xhtml1-transitional.dtd"><html><body>' . $this->data . '</body></html>'; 24 24 25 25 parent::prepare(); plugins/sfLucenePlugin/branches/1.1/lib/highlighter/sfLuceneHighlighterXML.class.php
r6911 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Highlighter 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ … … 48 48 $this->document = new DomDocument($this->version, $this->encoding); 49 49 $this->document->resolveExternals = true; 50 $this->document->substituteEntities = true;50 $this->document->substituteEntities = false; 51 51 52 52 if (!$this->document->loadXML($this->data)) … … 92 92 protected function doHighlightNode(DOMNode $node) 93 93 { 94 $texts = array(); 95 96 if (!$node->hasChildNodes()) 94 if ($this->ignoreNode($node)) 97 95 { 98 96 return; 99 97 } 98 99 $texts = array(); 100 100 101 101 foreach ($node->childNodes as $child) … … 118 118 119 119 /** 120 * Determines if the node should be ignored. If this returns true, then 121 * it and all children are ignored. If false, then it is highlighted. 122 */ 123 protected function ignoreNode(DOMNode $node) 124 { 125 switch ($node->nodeType) 126 { 127 case XML_ATTRIBUTE_NODE: 128 case XML_ENTITY_REF_NODE: 129 case XML_ENTITY_NODE: 130 case XML_PI_NODE: 131 case XML_COMMENT_NODE: 132 case XML_DOCUMENT_TYPE_NODE: 133 case XML_DOCUMENT_FRAG_NODE: 134 case XML_NOTATION_NODE: 135 return true; 136 } 137 138 if (!$node->hasChildNodes()) 139 { 140 return true; 141 } 142 143 return false; 144 } 145 146 /** 120 147 * Highlights a text node 121 148 * … … 124 151 protected function doHighlightTextNode(DOMNode $node) 125 152 { 126 foreach ($this->tokenize($node-> nodeValue) as $token)153 foreach ($this->tokenize($node->textContent) as $token) 127 154 { 128 155 $node->splitText($token->getEnd()); plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneActionIndexer.class.php
r6792 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneActionIndexerHandler.class.php
r6793 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneIndexer.class.php
r6816 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 136 136 protected function addCategory($category, $c = 1) 137 137 { 138 $this->getSearch()->getCategories ()->getCategory($category)->add($c)->getHolder()->save();138 $this->getSearch()->getCategoriesHarness()->getCategory($category)->add($c); 139 139 } 140 140 … … 146 146 protected function removeCategory($category, $c = 1) 147 147 { 148 $this->getSearch()->getCategories ()->getCategory($category)->subtract($c)->getHolder()->save();148 $this->getSearch()->getCategoriesHarness()->getCategory($category)->subtract($c); 149 149 } 150 150 plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneIndexerFactory.class.php
r6703 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneIndexerHandler.class.php
r6247 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneModelIndexer.class.php
r6816 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLuceneModelIndexerHandler.class.php
r6489 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLucenePropelIndexer.class.php
r6816 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/indexer/sfLucenePropelIndexerHandler.class.php
r6810 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/lib/results/sfLuceneActionResult.class.php
r6247 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 12 12 * @package sfLucenePlugin 13 13 * @subpackage Results 14 * @author Carl Vondrick <carl v@carlsoft.net>14 * @author Carl Vondrick <carl@carlsoft.net> 15 15 * @version SVN: $Id$ 16 16 */ plugins/sfLucenePlugin/branches/1.1/lib/results/sfLuceneModelResult.class.php
r6771 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 12 12 * @package sfLucenePlugin 13 13 * @subpackage Results 14 * @author Carl Vondrick <carl v@carlsoft.net>14 * @author Carl Vondrick <carl@carlsoft.net> 15 15 * @version SVN: $Id$ 16 16 */ plugins/sfLucenePlugin/branches/1.1/lib/results/sfLucenePager.class.php
r6792 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 * @package sfLucenePlugin 18 18 * @subpackage Results 19 * @author Carl Vondrick <carl v@carlsoft.net>19 * @author Carl Vondrick <carl@carlsoft.net> 20 20 * @version SVN: $Id$ 21 21 */ plugins/sfLucenePlugin/branches/1.1/lib/results/sfLuceneResult.class.php
r6792 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 12 12 * @package sfLucenePlugin 13 13 * @subpackage Results 14 * @author Carl Vondrick <carl v@carlsoft.net>14 * @author Carl Vondrick <carl@carlsoft.net> 15 15 * @version SVN: $Id$ 16 16 */ plugins/sfLucenePlugin/branches/1.1/lib/results/sfLuceneResults.class.php
r6792 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 16 16 * @package sfLucenePlugin 17 17 * @subpackage Results 18 * @author Carl Vondrick <carl v@carlsoft.net>18 * @author Carl Vondrick <carl@carlsoft.net> 19 19 * @version SVN: $Id$ 20 20 */ plugins/sfLucenePlugin/branches/1.1/lib/sfLucene.class.php
r6808 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 16 16 * the Zend Search Lucene library. 17 17 * 18 * @author Carl Vondrick <carl v@carlsoft.net>18 * @author Carl Vondrick <carl@carlsoft.net> 19 19 * @package sfLucenePlugin 20 20 * @version SVN: $Id$ … … 22 22 class sfLucene 23 23 { 24 /** 25 * Holds various misc. parameters 24 const VERSION = '0.2-DEV'; 25 26 /** 27 * Holds the internal dispatcher for this Lucene instance. 28 */ 29 protected $dispatcher = null; 30 31 /** 32 * Holds the Lucene instance 33 */ 34 protected $lucene = null; 35 36 /** 37 * Holds the indexer factory singleton 38 */ 39 protected $indexerFactory = null; 40 41 /** 42 * Holds the categories singleton 43 */ 44 protected $categoriesHarness = null; 45 46 /** 47 * Holds parameters for this lucene instance 26 48 */ 27 49 protected $parameters = null; … … 50 72 $this->setParameter('index_location', sfConfig::get('sf_data_dir') . DIRECTORY_SEPARATOR.'index'.DIRECTORY_SEPARATOR . $name . DIRECTORY_SEPARATOR . $culture); 51 73 52 $this-> setParameter('event_dispatcher', new sfEventDispatcher);74 $this->dispatcher = new sfEventDispatcher; 53 75 54 76 $this->initialize(); … … 227 249 * Returns the categories for this index. 228 250 */ 229 public function getCategories ()230 { 231 if ( !$this->getParameterHolder()->has('categories'))232 { 233 $this-> setParameter('categories', new sfLuceneCategories($this));234 } 235 236 return $this-> getParameter('categories');251 public function getCategoriesHarness() 252 { 253 if ($this->categoriesHarness == null) 254 { 255 $this->categoriesHarness = new sfLuceneCategories($this); 256 } 257 258 return $this->categoriesHarness; 237 259 } 238 260 … … 245 267 $location = $this->getParameter('index_location'); 246 268 247 if ( !$this->getParameterHolder()->has('lucene'))269 if ($this->lucene == null) 248 270 { 249 271 sfLuceneToolkit::loadZend(); … … 272 294 } 273 295 274 $this-> setParameter('lucene', $lucene);296 $this->lucene = $lucene; 275 297 } 276 298 277 return $this-> getParameter('lucene');299 return $this->lucene; 278 300 } 279 301 … … 282 304 * @return mixed An instance of the indexer factory. 283 305 */ 284 public function getIndexer ()285 { 286 if ( !$this->getParameterHolder()->has('indexer_factory'))287 { 288 $this-> setParameter('indexer_factory', new sfLuceneIndexerFactory($this));289 } 290 291 return $this-> getParameter('indexer_factory');306 public function getIndexerFactory() 307 { 308 if ($this->indexerFactory == null) 309 { 310 $this->indexerFactory = new sfLuceneIndexerFactory($this); 311 } 312 313 return $this->indexerFactory; 292 314 } 293 315 … … 297 319 public function getEventDispatcher() 298 320 { 299 return $this-> getParameter('event_dispatcher');321 return $this->dispatcher; 300 322 } 301 323 302 324 /** 303 325 * Gets the context. Right now, this exists for forward-compatability. 304 * TODO: Remove singleton 326 * TODO: Remove singleton (depends on sfConfiguration) 305 327 */ 306 328 public function getContext() … … 374 396 $this->getEventDispatcher()->notify(new sfEvent($this, 'lucene.log', array('Rebuilding index...'))); 375 397 376 $this->getCategories ()->clear()->save();398 $this->getCategoriesHarness()->clear(); 377 399 378 400 $original = $this->getParameter('delete_lock', false); 379 401 $this->setParameter('delete_lock', true); // tells the indexers not to bother deleting 380 402 381 foreach ($this->getIndexer ()->getHandlers() as $handler)403 foreach ($this->getIndexerFactory()->getHandlers() as $handler) 382 404 { 383 405 $handler->rebuild(); … … 588 610 public function friendlyFind($query) 589 611 { 590 return new sfLuceneResults( $this->find($query), $this);612 return new sfLuceneResults($this->find($query), $this); 591 613 } 592 614 … … 614 636 unset(self::$instances[$this->getParameter('name')][$this->getParameter('culture')]); 615 637 } 638 639 /** 640 * Force the index to use a Lucene instance. Do not ever use except for unit 641 * testing. 642 */ 643 public function forceLucene($lucene) 644 { 645 $this->lucene = $lucene; 646 } 647 648 /** 649 * Force the index to use a indexer factory. Do not ever use except for unit 650 * testing. 651 */ 652 public function forceIndexerFactory($factory) 653 { 654 $this->indexerFactory = $factory; 655 } 616 656 } plugins/sfLucenePlugin/branches/1.1/lib/storage/sfLuceneStorage.class.php
r6440 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 12 12 * @package sfLucenePlugin 13 13 * @subpackage Storage 14 * @author Carl Vondrick <carl v@carlsoft.net>14 * @author Carl Vondrick <carl@carlsoft.net> 15 15 * @version SVN: $Id$ 16 16 */ plugins/sfLucenePlugin/branches/1.1/lib/storage/sfLuceneStorageBlackhole.class.php
r6816 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Storage 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/storage/sfLuceneStorageFilesystem.class.php
r6657 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 12 12 * @package sfLucenePlugin 13 13 * @subpackage Storage 14 * @author Carl Vondrick <carl v@carlsoft.net>14 * @author Carl Vondrick <carl@carlsoft.net> 15 15 * @version SVN: $Id$ 16 16 */ plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneAboutTask.class.php
r6580 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 11 11 * Task that dumps information about sfLucene 12 12 * 13 * @author Carl Vondrick <carl v@carlsoft.net>13 * @author Carl Vondrick <carl@carlsoft.net> 14 14 * @package sfLucenePlugin 15 15 * @subpackage Tasks … … 46 46 $app = $arguments['application']; 47 47 48 $version = file_get_contents(dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR .'VERSION'); 49 50 $this->notifyListRow('Plugin Version', $version); 48 $this->notifyListRow('Plugin Version', 'sfLucene ' . sfLucene::VERSION); 51 49 52 50 if ($app) plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneBaseTask.class.php
r6792 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 11 11 * This class represents a base task for all sfLucene tasks. 12 12 * 13 * @author Carl Vondrick <carl v@carlsoft.net>13 * @author Carl Vondrick <carl@carlsoft.net> 14 14 * @package sfLucenePlugin 15 15 * @subpackage Tasks plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneCleanupTask.class.php
r6405 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 11 11 * This task rebuilds the entire index. 12 12 * 13 * @author Carl Vondrick <carl v@carlsoft.net>13 * @author Carl Vondrick <carl@carlsoft.net> 14 14 * @package sfLucenePlugin 15 15 * @subpackage Tasks plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneInitializeModuleTask.class.php
r6405 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 11 11 * Task that initializes a skeleton module to customize. 12 12 * 13 * @author Carl Vondrick <carl v@carlsoft.net>13 * @author Carl Vondrick <carl@carlsoft.net> 14 14 * @package sfLucenePlugin 15 15 * @subpackage Tasks plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneInitializeTask.class.php
r6405 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 11 11 * Task that initializes all the configuration files. 12 12 * 13 * @author Carl Vondrick <carl v@carlsoft.net>13 * @author Carl Vondrick <carl@carlsoft.net> 14 14 * @package sfLucenePlugin 15 15 * @subpackage Tasks plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneOptimizeTask.class.php
r6792 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 11 11 * This task optimizes all the indexes. 12 12 * 13 * @author Carl Vondrick <carl v@carlsoft.net>13 * @author Carl Vondrick <carl@carlsoft.net> 14 14 * @package sfLucenePlugin 15 15 * @subpackage Tasks plugins/sfLucenePlugin/branches/1.1/lib/task/sfLuceneRebuildTask.class.php
r6792 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 11 11 * This task rebuilds the entire index. 12 12 * 13 * @author Carl Vondrick <carl v@carlsoft.net>13 * @author Carl Vondrick <carl@carlsoft.net> 14 14 * @package sfLucenePlugin 15 15 * @subpackage Tasks plugins/sfLucenePlugin/branches/1.1/lib/util/sfLuceneBrowser.class.php
r6288 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 12 12 * @package sfLucenePlugin 13 13 * @subpackage Utilities 14 * @author Carl Vondrick <carl v@carlsoft.net>14 * @author Carl Vondrick <carl@carlsoft.net> 15 15 * @version SVN: $Id$ 16 16 */ plugins/sfLucenePlugin/branches/1.1/lib/util/sfLuceneCriteria.class.php
r6808 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 21 21 * @package sfLucenePlugin 22 22 * @subpackage Utilities 23 * @author Carl Vondrick <carl v@carlsoft.net>23 * @author Carl Vondrick <carl@carlsoft.net> 24 24 * @version SVN: $Id$ 25 25 */ plugins/sfLucenePlugin/branches/1.1/lib/util/sfLuceneToolkit.class.php
r6655 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Utilities 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/widget/sfLuceneWidgetFormatter.class.php
r6525 r7108 2 2 /* 3 3 * This file is part of the sfLucenePLugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Widget 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/widget/sfLuceneWidgetFormatterAdvanced.class.php
r6525 r7108 2 2 /* 3 3 * This file is part of the sfLucenePLugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Widget 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/lib/widget/sfLuceneWidgetFormatterSimple.class.php
r6525 r7108 2 2 /* 3 3 * This file is part of the sfLucenePLugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Widget 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/actions/actions.class.php
r6247 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 14 14 * @package sfLucenePlugin 15 15 * @subpackage Module 16 * @author Carl Vondrick <carl v@carlsoft.net>16 * @author Carl Vondrick <carl@carlsoft.net> 17 17 * @version SVN: $Id$ 18 18 */ plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/actions/components.class.php
r6247 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 14 14 * @package sfLucenePlugin 15 15 * @subpackage Module 16 * @author Carl Vondrick <carl v@carlsoft.net>16 * @author Carl Vondrick <carl@carlsoft.net> 17 17 * @version SVN: $Id$ 18 18 */ plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/lib/BasesfLuceneActions.class.php
r6808 r7108 2 2 /* 3 3 * This file is part of the sfLucenePLugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 13 13 * @package sfLucenePlugin 14 14 * @subpackage Module 15 * @author Carl Vondrick <carl v@carlsoft.net>15 * @author Carl Vondrick <carl@carlsoft.net> 16 16 * @version SVN: $Id$ 17 17 */ … … 200 200 protected function configureCategories($form) 201 201 { 202 $categories = $this->getLuceneInstance()->getCategories ()->getAllCategories();202 $categories = $this->getLuceneInstance()->getCategoriesHarness()->getAllCategories(); 203 203 204 204 if (!sfConfig::get('app_lucene_categories', true) || count($categories) == 0) plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/lib/BasesfLuceneComponents.class.php
r6577 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 11 11 * @package sfLucenePlugin 12 12 * @subpackage Module 13 * @author Carl Vondrick <carl v@carlsoft.net>13 * @author Carl Vondrick <carl@carlsoft.net> 14 14 * @version SVN: $Id$ 15 15 */ plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_actionResult.php
r6247 r7108 3 3 * @package sfLucenePlugin 4 4 * @subpackage Module 5 * @author Carl Vondrick <carl v@carlsoft.net>5 * @author Carl Vondrick <carl@carlsoft.net> 6 6 * @version SVN: $Id$ 7 7 */ plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_categories.php
r6247 r7108 3 3 * @package sfLucenePlugin 4 4 * @subpackage Module 5 * @author Carl Vondrick <carl v@carlsoft.net>5 * @author Carl Vondrick <carl@carlsoft.net> 6 6 * @version SVN: $Id$ 7 7 */ plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_controls.php
r6525 r7108 3 3 * @package sfLucenePlugin 4 4 * @subpackage Module 5 * @author Carl Vondrick <carl v@carlsoft.net>5 * @author Carl Vondrick <carl@carlsoft.net> 6 6 * @version SVN: $Id$ 7 7 */ plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_modelResult.php
r6247 r7108 3 3 * @package sfLucenePlugin 4 4 * @subpackage Module 5 * @author Carl Vondrick <carl v@carlsoft.net>5 * @author Carl Vondrick <carl@carlsoft.net> 6 6 * @version SVN: $Id$ 7 7 */ plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_pagerNavigation.php
r6577 r7108 3 3 * @package sfLucenePlugin 4 4 * @subpackage Module 5 * @author Carl Vondrick <carl v@carlsoft.net>5 * @author Carl Vondrick <carl@carlsoft.net> 6 6 * @version SVN: $Id$ 7 7 */ plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/_publicControls.php
r6247 r7108 3 3 * @package sfLucenePlugin 4 4 * @subpackage Module 5 * @author Carl Vondrick <carl v@carlsoft.net>5 * @author Carl Vondrick <carl@carlsoft.net> 6 6 * @version SVN: $Id$ 7 7 */ plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/advancedControls.php
r6528 r7108 3 3 * @package sfLucenePlugin 4 4 * @subpackage Module 5 * @author Carl Vondrick <carl v@carlsoft.net>5 * @author Carl Vondrick <carl@carlsoft.net> 6 6 * @version SVN: $Id$ 7 7 */ plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/searchControls.php
r6525 r7108 3 3 * @package sfLucenePlugin 4 4 * @subpackage Module 5 * @author Carl Vondrick <carl v@carlsoft.net>5 * @author Carl Vondrick <carl@carlsoft.net> 6 6 * @version SVN: $Id$ 7 7 */ plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/searchNoResults.php
r6525 r7108 3 3 * @package sfLucenePlugin 4 4 * @subpackage Module 5 * @author Carl Vondrick <carl v@carlsoft.net>5 * @author Carl Vondrick <carl@carlsoft.net> 6 6 * @version SVN: $Id$ 7 7 */ plugins/sfLucenePlugin/branches/1.1/modules/sfLucene/templates/searchResults.php
r6577 r7108 3 3 * @package sfLucenePlugin 4 4 * @subpackage Module 5 * @author Carl Vondrick <carl v@carlsoft.net>5 * @author Carl Vondrick <carl@carlsoft.net> 6 6 * @version SVN: $Id$ 7 7 */ plugins/sfLucenePlugin/branches/1.1/package.xml
r6656 r7108 3 3 <name>sfLucenePlugin</name> 4 4 <channel>pear.symfony-project.com</channel> 5 <summary> sfLucene instantly adds a search engine to your application.</summary>6 <description> sfLucene integrates symfony, your ORM layer, and Zend Search Lucene together to instantly add a powerful but flexible search engine.</description>5 <summary>A symfony plugin</summary> 6 <description>A symfony plugin</description> 7 7 <lead> 8 <name >Carl Vondrick</name>9 <user >carl</user>10 <email >carl@carlsoft.net</email>11 <active >yes</active>8 <name/> 9 <user/> 10 <email/> 11 <active/> 12 12 </lead> 13 <date>200 7-12-20</date>13 <date>2008-01-03</date> 14 14 <version> 15 <release>0. 2.0</release>16 <api>0. 2.0</api>15 <release>0.1.0</release> 16 <api>0.1.0</api> 17 17 </version> 18 18 <stability> 19 <release> devel</release>20 <api> devel</api>19 <release>beta</release> 20 <api>beta</api> 21 21 </stability> 22 22 <license uri="http://www.symfony-project.com/license">MIT license</license> 23 <notes>-</notes>23 <notes>-</notes> 24 24 25 <contents>25 <contents> 26 26 27 <dir name="/"><dir name="config"><file name="config_handlers.yml" role="data"/><file name="config.php" role="data"/></dir><dir name="doc"><dir name="generated"/><file name="build_docs.sh" role="data"/></dir><dir name="lib"><dir name="behavior"><file name="sfLucenePropelBehavior.class.php" role="data"/><file name="sfLucenePropelInitializer.class.php" role="data"/></dir><dir name="results"><file name="sfLuceneResults.class.php" role="data"/><file name="sfLuceneActionResult.class.php" role="data"/><file name="sfLucenePager.class.php" role="data"/><file name="sfLuceneResult.class.php" role="data"/><file name="sfLuceneModelResult.class.php" role="data"/></dir><dir name="addon"><dir name="Zend"><dir name="Search"><dir name="Lucene"><file name="sfLuceneFileStorage.class.php" role="data"/><file name="sfLuceneDirectoryStorage.class.php" role="data"/><file name="sfLuceneLowerCaseFilter.class.php" role="data"/></dir></dir></dir></dir><dir name="config"><file name="sfLuceneModuleConfigHandler.class.php" role="data"/><file name="sfLuceneProjectConfigHandler.class.php" role="data"/></dir><dir name="filter"><dir name="browser"><file name="sfLuceneRenderingFilter.class.php" role="data"/><file name="sfLuceneCacheFilter.class.php" role="data"/><file name="sfLuceneExecutionFilter.class.php" role="data"/></dir><file name="sfLuceneHighlightFilter.class.php" role="data"/></dir><dir name="listener"><file name="sfLuceneDoctrineListener.class.php" role="data"/></dir><dir name="util"><file name="sfLuceneCriteria.class.php" role="data"/><file name="sfLuceneBrowser.class.php" role="data"/><file name="sfLuceneToolkit.class.php" role="data"/><file name="sfLuceneHighlighter.class.php" role="data"/></dir><dir name="vendor"><dir name="Zend"><dir name="Search"><dir name="Lucene"><dir name="Analysis"><dir name="Analyzer"><dir name="Common"><dir name="Text"><file name="CaseInsensitive.php" role="data"/></dir><dir name="TextNum"><file name="CaseInsensitive.php" role="data"/></dir><file name="Text.php" role="data"/><file name="TextNum.php" role="data"/><file name="Utf8.php" role="data"/><file name="Utf8Num.php" role="data"/></dir><file name="Common.php" role="data"/></dir><dir name="TokenFilter"><file name="ShortWords.php" role="data"/><file name="LowerCase.php" role="data"/><file name="StopWords.php" role="data"/></dir><file name="Token.php" role="data"/><file name="Analyzer.php" role="data"/><file name="TokenFilter.php" role="data"/></dir><dir name="Storage"><dir name="File"><file name="Filesystem.php" role="data"/><file name="Memory.php" role="data"/></dir><dir name="Directory"><file name="Filesystem.php" role="data"/></dir><file name="File.php" role="data"/><file name="Directory.php" role="data"/></dir><dir name="Search"><dir name="Query"><file name="Wildcard.php" role="data"/><file name="Range.php" role="data"/><file name="Empty.php" role="data"/><file name="Boolean.php" role="data"/><file name="MultiTerm.php" role="data"/><file name="Phrase.php" role="data"/><file name="Insignificant.php" role="data"/><file name="Term.php" role="data"/><file name="Fuzzy.php" role="data"/></dir><dir name="Similarity"><file name="Default.php" role="data"/></dir><dir name="QueryEntry"><file name="Subquery.php" role="data"/><file name="Phrase.php" role="data"/><file name="Term.php" role="data"/></dir><dir name="Weight"><file name="Empty.php" role="data"/><file name="Boolean.php" role="data"/><file name="MultiTerm.php" role="data"/><file name="Phrase.php" role="data"/><file name="Term.php" role="data"/></dir><file name="QueryHit.php" role="data"/><file name="QueryParserException.php" role="data"/><file name="QueryParser.php" role="data"/><file name="Query.php" role="data"/><file name="QueryLexer.php" role="data"/><file name="QueryToken.php" role="data"/><file name="Similarity.php" role="data"/><file name="BooleanExpressionRecognizer.php" role="data"/><file name="QueryEntry.php" role="data"/><file name="QueryParserContext.php" role="data"/><file name="Weight.php" role="data"/></dir><dir name="Index"><dir name="SegmentWriter"><file name="DocumentWriter.php" role="data"/><file name="StreamWriter.php" role="data"/></dir><file name="DictionaryLoader.php" role="data"/><file name="Writer.php" role="data"/><file name="SegmentInfo.php" role="data"/><file name="FieldInfo.php" role="data"/><file name="SegmentWriter.php" role="data"/><file name="TermInfo.php" role="data"/><file name="SegmentMerger.php" role="data"/><file name="SegmentInfoPriorityQueue.php" role="data"/><file name="Term.php" role="data"/></dir><dir name="Document"><file name="Html.php" role="data"/></dir><file name="Document.php" role="data"/><file name="Exception.php" role="data"/><file name="Interface.php" role="data"/><file name="Proxy.php" role="data"/><file name="FSMAction.php" role="data"/><file name="Field.php" role="data"/><file name="FSM.php" role="data"/><file name="PriorityQueue.php" role="data"/></dir><file name="Lucene.php" role="data"/><file name="TODO.txt" role="data"/><file name="Exception.php" role="data"/></dir><file name="LICENSE.txt" role="data"/><file name="Exception.php" role="data"/></dir></dir><dir name="exception"><file name="sfLuceneResultsException.class.php" role="data"/><file name="sfLuceneHighlighterException.class.php" role="data"/><file name="sfLuceneIndexerException.class.php" role="data"/><file name="sfLuceneException.class.php" role="data"/></dir><dir name="indexer"><file name="sfLucenePropelIndexer.class.php" role="data"/><file name="sfLuceneDoctrineIndexer.class.php" role="data"/><file name="sfLuceneIndexerFactory.class.php" role="data"/><file name="sfLuceneActionIndexerHandler.class.php" role="data"/><file name="sfLuceneActionIndexer.class.php" role="data"/><file name="sfLuceneIndexerHandler.class.php" role="data"/><file name="sfLuceneModelIndexerHandler.class.php" role="data"/><file name="sfLuceneIndexer.class.php" role="data"/><file name="sfLuceneMediaIndexer.class.php" role="data"/><file name="sfLucenePropelIndexerHandler.class.php" role="data"/><file name="sfLuceneModelIndexer.class.php" role="data"/></dir><file name="sfLucene.class.php" role="data"/><dir name="task"><file name="sfLuceneBaseTask.class.php" role="data"/><file name="sfLuceneRebuildTask.class.php" role="data"/><file name="sfLuceneInitializeTask.class.php" role="data"/><file name="sfLuceneAboutTask.class.php" role="data"/><file name="sfLuceneOptimizeTask.class.php" role="data"/><file name="sfLuceneInitializeModuleTask.class.php" role="data"/><file name="sfLuceneCleanupTask.class.php" role="data"/></dir><dir name="category"><file name="sfLuceneCategories.class.php" role="data"/><file name="sfLuceneCategory.class.php" role="data"/></dir><dir name="storage"><file name="sfLuceneStorageBlackhole.class.php" role="data"/><file name="sfLuceneStorageFilesystem.class.php" role="data"/><file name="sfLuceneStorage.class.php" role="data"/></dir><dir name="form"><file name="sfLuceneSimpleForm.class.php" role="data"/><file name="sfLuceneSimpleFormBase.class.php" role="data"/><file name="sfLuceneAdvancedFormBase.class.php" role="data"/><file name="sfLuceneAdvancedForm.class.php" role="data"/><file name="sfLuceneForm.class.php" role="data"/></dir><dir name="widget"><file name="sfLuceneWidgetFormatter.class.php" role="data"/><file name="sfLuceneWidgetFormatterSimple.class.php" role="data"/><file name="sfLuceneWidgetFormatterAdvanced.class.php" role="data"/></dir><dir name="helper"><file name="sfLuceneHelper.php" role="data"/></dir></dir><dir name="modules"><dir name="sfLucene"><dir name="actions"><file name="components.class.php" role="data"/><file name="actions.class.php" role="data"/></dir><dir name="config"><file name="view.yml" role="data"/></dir><dir name="lib"><file name="BasesfLuceneComponents.class.php" role="data"/><file name="BasesfLuceneActions.class.php" role="data"/></dir><dir name="templates"><file name="searchControls.php" role="data"/><file name="_actionResult.php" role="data"/><file name="_pagerNavigation.php" role="data"/><file name="_modelResult.php" role="data"/><file name="_publicControls.php" role="data"/><file name="_controls.php" role="data"/><file name="_categories.php" role="data"/><file name="searchNoResults.php" role="data"/><file name="searchResults.php" role="data"/><file name="advancedControls.php" role="data"/></dir></dir></dir><dir name="data"><dir name="skeleton"><dir name="app"><dir name="config"><file name="search.yml" role="data"/></dir></dir><dir name="module"><dir name="actions"><file name="components.class.php" role="data"/><file name="actions.class.php" role="data"/></dir><dir name="templates"/></dir><dir name="project"><dir name="config"><file name="search.yml" role="data"/></dir></dir></dir></dir><dir name="web"><dir name="css"><file name="search.css" role="data"/></dir></dir><file name="LICENSE" role="data"/><file name="VERSION" role="data"/><file name="CHANGELOG" role="data"/><file name="package.xml.tpl" role="data"/><file name="package.xml" role="data"/><file name="README" role="data"/></dir></contents>27 <dir name="/"><dir name="config"><file name="config_handlers.yml" role="data"/></dir><dir name="doc"><dir name="generated"/><file name="build_docs.sh" role="data"/></dir><dir name="lib"><dir name="helper"><file name="sfLuceneHelper.php" role="data"/></dir><dir name="widget"><file name="sfLuceneWidgetFormatterSimple.class.php" role="data"/><file name="sfLuceneWidgetFormatter.class.php" role="data"/><file name="sfLuceneWidgetFormatterAdvanced.class.php" role="data"/></dir><dir name="filter"><dir name="browser"><file name="sfLuceneRenderingFilter.class.php" role="data"/><file name="sfLuceneCacheFilter.class.php" role="data"/><file name="sfLuceneExecutionFilter.class.php" role="data"/></dir><file name="sfLuceneHighlightFilter.class.php" role="data"/></dir><dir name="addon"><dir name="Zend"><file name="sfLuceneFileStorage.class.php" role="data"/><file name="sfLuceneDirectoryStorage.class.php" role="data"/><file name="sfLuceneLowerCaseFilter.class.php" role="data"/></dir></dir><dir name="vendor"><dir name="Zend"><file name="LICENSE.txt" role="data"/><file name="Exception.php" role="data"/><dir name="Search"><dir name="Lucene"><dir name="Analysis"><dir name="Analyzer"><dir name="Common"><dir name="Text"><file name="CaseInsensitive.php" role="data"/></dir><dir name="TextNum"><file name="CaseInsensitive.php" role="data"/></dir><file name="Text.php" role="data"/><file name="TextNum.php" role="data"/><file name="Utf8.php" role="data"/><file name="Utf8Num.php" role="data"/></dir><file name="Common.php" role="data"/></dir><dir name="TokenFilter"><file name="ShortWords.php" role="data"/><file name="LowerCase.php" role="data"/><file name="StopWords.php" role="data"/></dir><file name="Token.php" role="data"/><file name="Analyzer.php" role="data"/><file name="TokenFilter.php" role="data"/></dir><dir name="Storage"><dir name="File"><file name="Filesystem.php" role="data"/><file name="Memory.php" role="data"/></dir><dir name="Directory"><file name="Filesystem.php" role="data"/></dir><file name="File.php" role="data"/><file name="Directory.php" role="data"/></dir><dir name="Search"><dir name="Query"><file name="Wildcard.php" role="data"/><file name="Range.php" role="data"/><file name="Empty.php" role="data"/><file name="Boolean.php" role="data"/><file name="MultiTerm.php" role="data"/><file name="Phrase.php" role="data"/><file name="Insignificant.php" role="data"/><file name="Fuzzy.php" role="data"/><file name="Term.php" role="data"/></dir><dir name="Similarity"><file name="Default.php" role="data"/></dir><dir name="QueryEntry"><file name="Subquery.php" role="data"/><file name="Phrase.php" role="data"/><file name="Term.php" role="data"/></dir><dir name="Weight"><file name="Empty.php" role="data"/><file name="Boolean.php" role="data"/><file name="MultiTerm.php" role="data"/><file name="Phrase.php" role="data"/><file name="Term.php" role="data"/></dir><file name="QueryHit.php" role="data"/><file name="QueryParserException.php" role="data"/><file name="QueryParser.php" role="data"/><file name="Query.php" role="data"/><file name="QueryLexer.php" role="data"/><file name="QueryToken.php" role="data"/><file name="Similarity.php" role="data"/><file name="BooleanExpressionRecognizer.php" role="data"/><file name="QueryEntry.php" role="data"/><file name="QueryParserContext.php" role="data"/><file name="Weight.php" role="data"/></dir><dir name="Index"><dir name="SegmentWriter"><file name="DocumentWriter.php" role="data"/><file name="StreamWriter.php" role="data"/></dir><file name="DictionaryLoader.php" role="data"/><file name="Writer.php" role="data"/><file name="SegmentInfo.php" role="data"/><file name="FieldInfo.php" role="data"/><file name="SegmentWriter.php" role="data"/><file name="TermInfo.php" role="data"/><file name="SegmentMerger.php" role="data"/><file name="SegmentInfoPriorityQueue.php" role="data"/><file name="Term.php" role="data"/></dir><dir name="Document"><file name="Html.php" role="data"/></dir><file name="Document.php" role="data"/><file name="Exception.php" role="data"/><file name="Interface.php" role="data"/><file name="Proxy.php" role="data"/><file name="FSMAction.php" role="data"/><file name="Field.php" role="data"/><file name="FSM.php" role="data"/><file name="PriorityQueue.php" role="data"/></dir><file name="Lucene.php" role="data"/><file name="TODO.txt" role="data"/><file name="Exception.php" role="data"/></dir></dir></dir><dir name="indexer"><file name="sfLucenePropelIndexer.class.php" role="data"/><file name="sfLuceneIndexerFactory.class.php" role="data"/><file name="sfLuceneActionIndexerHandler.class.php" role="data"/><file name="sfLuceneActionIndexer.class.php" role="data"/><file name="sfLuceneIndexerHandler.class.php" role="data"/><file name="sfLuceneModelIndexerHandler.class.php" role="data"/><file name="sfLuceneIndexer.class.php" role="data"/><file name="sfLucenePropelIndexerHandler.class.php" role="data"/><file name="sfLuceneModelIndexer.class.php" role="data"/></dir><dir name="exception"><file name="sfLuceneResultsException.class.php" role="data"/><file name="sfLuceneHighlighterException.class.php" role="data"/><file name="sfLuceneIndexerException.class.php" role="data"/><file name="sfLuceneException.class.php" role="data"/><file name="sfLuceneHighlighterXMLException.class.php" role="data"/></dir><dir name="behavior"><file name="sfLucenePropelBehavior.class.php" role="data"/><file name="sfLucenePropelInitializer.class.php" role="data"/></dir><dir name="results"><file name="sfLuceneResults.class.php" role="data"/><file name="sfLuceneActionResult.class.php" role="data"/><file name="sfLucenePager.class.php" role="data"/><file name="sfLuceneResult.class.php" role="data"/><file name="sfLuceneModelResult.class.php" role="data"/></dir><dir name="task"><file name="sfLuceneOptimizeTask.class.php" role="data"/><file name="sfLuceneInitializeTask.class.php" role="data"/><file name="sfLuceneRebuildTask.class.php" role="data"/><file name="sfLuceneCleanupTask.class.php" role="data"/><file name="sfLuceneInitializeModuleTask.class.php" role="data"/><file name="sfLuceneAboutTask.class.php" role="data"/><file name="sfLuceneBaseTask.class.php" role="data"/></dir><dir name="form"><file name="sfLuceneForm.class.php" role="data"/><file name="sfLuceneAdvancedFormBase.class.php" role="data"/><file name="sfLuceneSimpleFormBase.class.php" role="data"/><file name="sfLuceneAdvancedForm.class.php" role="data"/><file name="sfLuceneSimpleForm.class.php" role="data"/></dir><dir name="storage"><file name="sfLuceneStorage.class.php" role="data"/><file name="sfLuceneStorageBlackhole.class.php" role="data"/><file name="sfLuceneStorageFilesystem.class.php" role="data"/></dir><dir name="config"><file name="sfLuceneModuleConfigHandler.class.php" role="data"/><file name="sfLuceneProjectConfigHandler.class.php" role="data"/></dir><dir name="util"><file name="sfLuceneCriteria.class.php" role="data"/><file name="sfLuceneBrowser.class.php" role="data"/><file name="sfLuceneToolkit.class.php" role="data"/></dir><dir name="category"><file name="sfLuceneCategories.class.php" role="data"/><file name="sfLuceneCategory.class.php" role="data"/></dir><file name="sfLucene.class.php" role="data"/><dir name="event"><file name="sfLuceneEventConnector.class.php" role="data"/><file name="sfLuceneEventConnectorLogger.class.php" role="data"/></dir><dir name="highlighter"><dir name="marker"><file name="sfLuceneHighlighterMarker.class.php" role="data"/><file name="sfLuceneHighlighterMarkerSprint.class.php" role="data"/><file name="sfLuceneHighlighterMarkerHarness.class.php" role="data"/><file name="sfLuceneHighlighterMarkerUppercase.class.php" role="data"/><file name="sfLuceneHighlighterMarkerDry.class.php" role="data"/></dir><file name="sfLuceneHighlighterXHTMLPart.class.php" role="data"/><file name="sfLuceneHighlighterHTML.class.php" role="data"/><dir name="keyword"><file name="sfLuceneHighlighterKeyword.class.php" role="data"/><file name="sfLuceneHighlighterKeywordZend.class.php" role="data"/><file name="sfLuceneHighlighterKeywordNamed.class.php" role="data"/><file name="sfLuceneHighlighterKeywordNamedInsensitive.class.php" role="data"/><file name="sfLuceneHighlighterToken.class.php" role="data"/></dir><file name="sfLuceneHighlighterString.class.php" role="data"/><file name="sfLuceneHighlighterHTMLPart.class.php" role="data"/><file name="sfLuceneHighlighterXHTML.class.php" role="data"/><file name="sfLuceneHighlighter.class.php" role="data"/><file name="sfLuceneHighlighterXML.class.php" role="data"/></dir></dir><dir name="modules"><dir name="sfLucene"><dir name="actions"><file name="components.class.php" role="data"/><file name="actions.class.php" role="data"/></dir><dir name="config"><file name="view.yml" role="data"/></dir><dir name="lib"><file name="BasesfLuceneComponents.class.php" role="data"/><file name="BasesfLuceneActions.class.php" role="data"/></dir><dir name="templates"><file name="advancedControls.php" role="data"/><file name="searchControls.php" role="data"/><file name="_actionResult.php" role="data"/><file name="_pagerNavigation.php" role="data"/><file name="_modelResult.php" role="data"/><file name="_publicControls.php" role="data"/><file name="_controls.php" role="data"/><file name="_categories.php" role="data"/><file name="searchNoResults.php" role="data"/><file name="searchResults.php" role="data"/></dir></dir></dir><dir name="data"><dir name="skeleton"><dir name="app"><dir name="config"><file name="search.yml" role="data"/></dir></dir><dir name="module"><dir name="actions"><file name="components.class.php" role="data"/><file name="actions.class.php" role="data"/></dir><dir name="templates"/></dir><dir name="project"><dir name="config"><file name="search.yml" role="data"/></dir></dir></dir></dir><dir name="web"><dir name="css"><file name="search.css" role="data"/></dir></dir><file name="LICENSE" role="data"/><file name="VERSION" role="data"/><file name="CHANGELOG" role="data"/><file name="package.xml.tpl" role="data"/><file name="package.xml" role="data"/><file name="README" role="data"/><file name="XMLCatalog.tar.gz" role="data"/></dir></contents> 28 28 29 <dependencies>30 <required>31 <php>32 <min>5.2.0</min>33 </php>34 <pearinstaller>35 <min>1.4.1</min>36 </pearinstaller>37 <package>38 <name>sfLucenePlugin</name>39 <channel>pear.symfony-project.com</channel>40 <min>0.0.1</min>41 <max>1.1.0</max>42 <exclude>1.1.0</exclude>43 </package>44 </required>45 </dependencies>29 <dependencies> 30 <required> 31 <php> 32 <min>5.1.0</min> 33 </php> 34 <pearinstaller> 35 <min>1.4.1</min> 36 </pearinstaller> 37 <package> 38 <name>sfLucenePlugin</name> 39 <channel>pear.symfony-project.com</channel> 40 <min>0.0.1</min> 41 <max>1.1.0</max> 42 <exclude>1.1.0</exclude> 43 </package> 44 </required> 45 </dependencies> 46 46 47 <phprelease>48 </phprelease>47 <phprelease> 48 </phprelease> 49 49 50 <changelog>51 </changelog>50 <changelog> 51 </changelog> 52 52 </package> plugins/sfLucenePlugin/branches/1.1/test
- Property svn:externals set to
limeade http://svn.symfony-project.com/plugins/cvLimeadePlugin/trunk/lib
- Property svn:externals set to
plugins/sfLucenePlugin/branches/1.1/test/bin/AllFakeModels.php
r6392 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/test/bootstrap/unit.php
r6686 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 15 15 */ 16 16 17 $app = isset($app) ? $app : 'frontend';18 19 define('SF_ROOT_DIR', dirname(__FILE__) . '/../../../..');20 define('SF_APP', $app);21 define('SF_ENVIRONMENT', 'dev');22 define('SF_DEBUG', true);23 24 require_once SF_ROOT_DIR.DIRECTORY_SEPARATOR.'apps'.DIRECTORY_SEPARATOR.SF_APP.DIRECTORY_SEPARATOR.'config'.DIRECTORY_SEPARATOR.'config.php';25 26 sfContext::getInstance();27 28 17 error_reporting(E_ALL); 29 18 30 include(SF_ROOT_DIR.DIRECTORY_SEPARATOR.'config'.DIRECTORY_SEPARATOR.'config.php'); 31 require_once($sf_symfony_lib_dir.'/vendor/lime/lime.php'); 19 define('SF_ROOT_DIR', realpath(dirname(__FILE__) . '/../../../..')); 32 20 33 define('SANDBOX_DIR', dirname(dirname(__FILE__)) . '/sandbox');34 define('DATA_DIR', dirname(dirname(__FILE__)) . '/data');21 require_once SF_ROOT_DIR . '/config/config.php'; 22 require_once $sf_symfony_lib_dir . '/vendor/lime/lime.php'; 35 23 36 function clear_sandbox() 37 { 38 // clear sandbox 39 sfToolkit::clearDirectory(SANDBOX_DIR); 40 } 24 require_once dirname(__FILE__) . '/../limeade/limeade_loader.php'; 25 require_once dirname(__FILE__) . '/../bin/limeade_lucene.php'; 41 26 42 function configure_i18n($status = true, $culture = 'en_US') 43 { 44 if ($status) 45 { 46 sfConfig::add(array( 47 'sf_i18n_default_culture' => 'en_US', 48 'sf_i18n_source' => 'XLIFF', 49 'sf_i18n_debug' => false, 50 'sf_i18n_untranslated_prefix' => '[T]', 51 'sf_i18n_untranslated_suffix' => '[/T]', 52 )); 27 limeade_loader::all(); 53 28 54 sfConfig::set('sf_i18n', true);55 sfContext::getInstance()->set('i18n', new sfI18N(sfContext::getInstance()->getEventDispatcher()));56 }57 else58 {59 sfConfig::set('sf_i18n', false);60 sfContext::getInstance()->set('i18n', null);61 }62 }63 29 64 function remove_from_sfconfig($what)65 {66 $all = sfConfig::getAll();67 unset($all[$what]);68 sfConfig::clear();69 sfConfig::add($all);70 }71 72 clear_sandbox();73 74 sfConfig::set('sf_config_dir_name', dirname(__FILE__) . '/../data/config');75 sfConfig::set('sf_data_dir', SANDBOX_DIR . '/data');plugins/sfLucenePlugin/branches/1.1/test/coverage.php
r6671 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE plugins/sfLucenePlugin/branches/1.1/test/unit/addon/Zend/sfLuceneDirectoryStorageTest.php
r6681 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(7, new lime_output_color()); 19 $t = new limeade_test(7, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 22 23 $luceneade = new limeade_lucene($limeade); 24 $luceneade->configure()->clear_sandbox(); 20 25 21 26 clearstatcache(); 22 27 23 $d = new sfLuceneDirectoryStorage( SANDBOX_DIR. '/really/long/path/to/something');28 $d = new sfLuceneDirectoryStorage($luceneade->sandbox_dir . '/really/long/path/to/something'); 24 29 25 30 clearstatcache(); 26 31 27 $t->is(substr(sprintf('%o', fileperms( SANDBOX_DIR. '/really/long/path/to/something')), -4), '0777', '__construct() sets permission to 0777');32 $t->is(substr(sprintf('%o', fileperms($luceneade->sandbox_dir . '/really/long/path/to/something')), -4), '0777', '__construct() sets permission to 0777'); 28 33 29 34 $file = $d->createFile('foo'); 30 35 $t->isa_ok($file, 'sfLuceneFileStorage', '->createFile() returns an instance of sfLuceneFileStorage'); 31 $t->is(substr(sprintf('%o', fileperms( SANDBOX_DIR. '/really/long/path/to/something/foo')), -4), '0777', '->createFile() sets permission to 0777');36 $t->is(substr(sprintf('%o', fileperms($luceneade->sandbox_dir . '/really/long/path/to/something/foo')), -4), '0777', '->createFile() sets permission to 0777'); 32 37 33 38 $file = $d->createFile('foo'); 34 $t->is(substr(sprintf('%o', fileperms( SANDBOX_DIR. '/really/long/path/to/something/foo')), -4), '0777', '->createFile() sets permission to 0777 if it\'s created again');39 $t->is(substr(sprintf('%o', fileperms($luceneade->sandbox_dir . '/really/long/path/to/something/foo')), -4), '0777', '->createFile() sets permission to 0777 if it\'s created again'); 35 40 36 41 clearstatcache(); … … 40 45 $t->isa_ok($d->getFileObject('foo', false), 'sfLuceneFileStorage', '->getFileObject() returns an instance of sfLuceneFileStorage if told not to share'); 41 46 42 touch( SANDBOX_DIR. '/really/long/path/to/something/bar');47 touch($luceneade->sandbox_dir . '/really/long/path/to/something/bar'); 43 48 44 49 $t->isa_ok($d->getFileObject('bar'), 'sfLuceneFileStorage', '->getFileObject() returns an instance of sfLuceneFileStorage if the file exists but not handled'); plugins/sfLucenePlugin/branches/1.1/test/unit/addon/Zend/sfLuceneFileStorageTest.php
r6681 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(1, new lime_output_color()); 19 $t = new limeade_test(1, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 22 23 $luceneade = new limeade_lucene($limeade); 24 $luceneade->configure()->clear_sandbox(); 20 25 21 26 clearstatcache(); 22 27 23 touch( SANDBOX_DIR. '/foo');24 chmod( SANDBOX_DIR. '/foo', 0666);28 touch($luceneade->sandbox_dir . '/foo'); 29 chmod($luceneade->sandbox_dir . '/foo', 0666); 25 30 26 31 clearstatcache(); 27 32 28 new sfLuceneFileStorage( SANDBOX_DIR. '/foo');33 new sfLuceneFileStorage($luceneade->sandbox_dir . '/foo'); 29 34 30 35 clearstatcache(); 31 36 32 $t->is(substr(sprintf('%o', fileperms( SANDBOX_DIR. '/foo')), -4), '0777', '__construct() sets permission to 0777');37 $t->is(substr(sprintf('%o', fileperms($luceneade->sandbox_dir . '/foo')), -4), '0777', '__construct() sets permission to 0777'); plugins/sfLucenePlugin/branches/1.1/test/unit/addon/Zend/sfLuceneLowerCaseFilterTest.php
r6681 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(3, new lime_output_color()); 19 $t = new limeade_test(3, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 22 23 $luceneade = new limeade_lucene($limeade); 24 $luceneade->configure()->clear_sandbox(); 20 25 21 26 $filter = new sfLuceneLowerCaseFilter(false); plugins/sfLucenePlugin/branches/1.1/test/unit/behavior/sfLucenePropelBehaviorTest.php
r6733 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 16 16 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 require dirname(__FILE__) . '/../../bin/AllFakeModels.php'; 19 20 $t = new lime_test(26, new lime_output_color()); 18 19 $t = new limeade_test(30, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 22 23 $luceneade = new limeade_lucene($limeade); 24 $luceneade->configure()->clear_sandbox()->load_models(); 21 25 22 26 $m1 = new FakeForum; … … 51 55 { 52 56 return $this->getSearchInstances($node); 57 } 58 59 public function clear() 60 { 61 $this->saveQueue = array(); 62 $this->deleteQueue = array(); 53 63 } 54 64 } … … 150 160 $t->is($behavior->_getDeleteQueue(), array(1 => $m2), '->postDelete() removes deleting model from the queue'); 151 161 162 $t->diag('testing ::setLock()'); 163 164 $behavior->clear(); 165 166 sfLucenePropelBehavior::setLock(true); 167 168 $m1->setCoolness(4); 169 170 $behavior->preSave($m1); 171 $t->is(count($behavior->_getSaveQueue()), 0, '::setLock() disables the save queue'); 172 173 $behavior->preDelete($m1); 174 $t->is(count($behavior->_getDeleteQueue()), 0, '::setLock() disables the delete queue'); 175 176 $behavior->clear(); 177 178 sfLucenePropelBehavior::setLock(false); 179 180 $behavior->preSave($m1); 181 $t->is(count($behavior->_getSaveQueue()), 1, '::setLock() enables the save queue'); 182 183 $behavior->preDelete($m1); 184 $t->is(count($behavior->_getDeleteQueue()), 1, '::setLock() enables the delete queue'); 185 186 $behavior->clear(); 187 188 foreach (array($m1, $m2, $m3, $m3) as $m) 189 { 190 $indexer = new sfLucenePropelIndexer(sfLucene::getInstance('testLucene', 'en'), $m); 191 $indexer->delete(); 192 } 193 152 194 $t->diag('testing ->insertIndex()'); 153 195 plugins/sfLucenePlugin/branches/1.1/test/unit/behavior/sfLucenePropelInitializerTest.php
r6733 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 16 16 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 require dirname(__FILE__) . '/../../bin/AllFakeModels.php'; 19 20 $t = new lime_test(4, new lime_output_color()); 18 19 $t = new limeade_test(4, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 22 23 $luceneade = new limeade_lucene($limeade); 24 $luceneade->configure()->clear_sandbox()->load_models(); 21 25 22 26 class FooBehavior extends sfPropelBehavior plugins/sfLucenePlugin/branches/1.1/test/unit/category/sfLuceneCategoriesTest.php
r6489 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(20, new lime_output_color()); 19 $t = new limeade_test(20, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 22 23 $luceneade = new limeade_lucene($limeade); 24 $luceneade->configure()->clear_sandbox(); 20 25 21 26 $lucene = sfLucene::getInstance('testLucene', 'en'); plugins/sfLucenePlugin/branches/1.1/test/unit/category/sfLuceneCategoryTest.php
r6525 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(15, new lime_output_color()); 19 $t = new limeade_test(15, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 22 23 $luceneade = new limeade_lucene($limeade); 24 $luceneade->configure()->clear_sandbox(); 20 25 21 26 $lucene = sfLucene::getInstance('testLucene', 'en'); plugins/sfLucenePlugin/branches/1.1/test/unit/config/sfLuceneModuleConfigHandlerTest.php
r6696 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(2, new lime_output_color()); 19 $t = new limeade_test(2, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 22 23 $luceneade = new limeade_lucene($limeade); 24 $luceneade->configure()->clear_sandbox(); 20 25 21 26 $config = new sfLuceneModuleConfigHandler(); 22 27 23 $response = $config->execute(array( DATA_DIR. '/configTest/module.yml'));28 $response = $config->execute(array($luceneade->data_dir . '/configTest/module.yml')); 24 29 25 30 file_put_contents(lime_test::get_temp_directory() . '/search.yml.php', $response); plugins/sfLucenePlugin/branches/1.1/test/unit/config/sfLuceneProjectConfigHandlerTest.php
r6706 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(2, new lime_output_color()); 19 $t = new limeade_test(2, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 22 23 $luceneade = new limeade_lucene($limeade); 24 $luceneade->configure()->clear_sandbox()->load_models(); 20 25 21 26 $config = new sfLuceneProjectConfigHandler(); 22 27 23 $response = $config->execute(array( DATA_DIR. '/configTest/project.yml'));28 $response = $config->execute(array($luceneade->data_dir . '/configTest/project.yml')); 24 29 25 30 file_put_contents(lime_test::get_temp_directory() . '/search.yml.php', $response); plugins/sfLucenePlugin/branches/1.1/test/unit/event/sfLuceneEventConnectorLoggerTest.php
r6792 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(6, new lime_output_color()); 19 $t = new limeade_test(6, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 class FooListener plugins/sfLucenePlugin/branches/1.1/test/unit/event/sfLuceneEventConnectorTest.php
r6792 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(5, new lime_output_color()); 19 $t = new limeade_test(5, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 class FooListener plugins/sfLucenePlugin/branches/1.1/test/unit/filter/browser/sfLuceneCacheFilterTest.php
r6671 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(2, new lime_output_color()); 19 $t = new limeade_test(2, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 class Foo … … 33 35 34 36 try { 37 $ex = $t->no_exception('->execute() runs without an exception'); 35 38 $filter->execute($chain); 36 $ t->pass('->execute() runs without an exception');39 $ex->no(); 37 40 } catch (Exception $e) { 38 $ t->fail('->execute() runs without an exception');41 $ex->caught($e); 39 42 } 40 43 plugins/sfLucenePlugin/branches/1.1/test/unit/filter/browser/sfLuceneExecutionFilterTest.php
r6671 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(5, new lime_output_color()); 19 $t = new limeade_test(5, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 class FooFilter extends sfLuceneExecutionFilter … … 39 41 40 42 try { 43 $ex = $t->no_exception('->execute() runs without exception'); 41 44 $filter->execute($chain); 42 $ t->pass('->execute() runs without an exception');45 $ex->no(); 43 46 } catch (Exception $e) { 44 $ t->fail('->execute() runs without an exception');47 $ex->caught($e); 45 48 } 46 49 plugins/sfLucenePlugin/branches/1.1/test/unit/filter/browser/sfLuceneRenderingFilterTest.php
r6671 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(3, new lime_output_color()); 19 $t = new limeade_test(3, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 class Foo plugins/sfLucenePlugin/branches/1.1/test/unit/filter/sfLuceneHighlightFilterTest.php
r6891 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(20, new lime_output_color()); 19 $t = new limeade_test(20, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $chain = new sfFilterChain(); … … 157 159 $t->diag('testing i18n'); 158 160 159 configure_i18n();161 $i18n = $app->i18n()->setup('en_US'); 160 162 161 163 $response->setContent('<html><body>highlight the keyword</body></html>'); … … 164 166 165 167 $t->is($response->getContent(), "<?xml version=\"1.0\"?>\n<html><body>highlight the <highlighted>keyword</highlighted></body></html>\n", 'highlighter highlights a single keyword with i18n'); 168 169 $i18n->teardown(); plugins/sfLucenePlugin/branches/1.1/test/unit/form/sfLuceneAdvancedFormTest.php
r6525 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(10, new lime_output_color()); 19 $t = new limeade_test(10, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $t->diag('testing constructor'); plugins/sfLucenePlugin/branches/1.1/test/unit/form/sfLuceneFormTest.php
r6525 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(9, new lime_output_color()); 19 $t = new limeade_test(9, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 class DummyForm extends sfLuceneForm plugins/sfLucenePlugin/branches/1.1/test/unit/form/sfLuceneSimpleFormTest.php
r6577 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(12, new lime_output_color()); 19 $t = new limeade_test(12, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $t->diag('testing constructor'); plugins/sfLucenePlugin/branches/1.1/test/unit/helper/sfLuceneHelperTest.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 16 16 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 19 $t = new limeade_test(16, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 18 22 19 23 sfLuceneToolkit::loadZend(); … … 49 53 $foo = new Foo; 50 54 $bar = new Bar; 51 52 $t = new lime_test(16, new lime_output_color());53 55 54 56 $t->diag('testing partial dependencies'); plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/keyword/sfLuceneHighlighterKeywordNamedInsensitiveTest.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(15, new lime_output_color()); 19 $t = new limeade_test(15, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $highlighter = new sfLuceneHighlighterMarkerDry; plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/keyword/sfLuceneHighlighterKeywordNamedTest.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(18, new lime_output_color()); 19 $t = new limeade_test(18, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $highlighter = new sfLuceneHighlighterMarkerDry; plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/keyword/sfLuceneHighlighterKeywordZendTest.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime _test(1, new lime_output_color());19 $t = new limeade_test(1, limeade_output::get()); 20 20 21 21 $t->todo('Implementation'); plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/keyword/sfLuceneHighlighterTokenTest.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(8, new lime_output_color()); 19 $t = new limeade_test(8, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $kw = new sfLuceneHighlighterKeywordNamed(new sfLuceneHighlighterMarkerDry, 'foo'); plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/marker/sfLuceneHighlighterMarkerDryTest.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(3, new lime_output_color()); 19 $t = new limeade_test(3, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $marker = new sfLuceneHighlighterMarkerDry; plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/marker/sfLuceneHighlighterMarkerHarnessTest.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(6, new lime_output_color()); 19 $t = new limeade_test(6, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $lighters = array( plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/marker/sfLuceneHighlighterMarkerSprintTest.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(4, new lime_output_color()); 19 $t = new limeade_test(4, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 try { plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/marker/sfLuceneHighlighterMarkerUppercaseTest.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(3, new lime_output_color()); 19 $t = new limeade_test(3, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $marker = new sfLuceneHighlighterMarkerUppercase; plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterHTMLPartTest.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(1, new lime_output_color()); 19 $t = new limeade_test(2, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $given = '<p>This is part of a document, dedicated to foobar.</p><p>Look, a foobar</p>'; 22 23 24 $expected = '<p>This is part of a document, dedicated to <h>foobar</h>.</p> 24 25 <p>Look, a <h>foobar</h></p> … … 32 33 33 34 $t->is($highlighter->export(), $expected, '->highlight() highlights a part of the document and returns just that part'); 35 36 $given = '<p>This is pàrt of a document, dedicated to foobar.</p>'; 37 $expected = '<p>This is pàrt of a document, dedicated to <h>foobar</h>.</p> 38 '; 39 40 $keyword = new sfLuceneHighlighterKeywordNamed(new sfLuceneHighlighterMarkerSprint('<h>%s</h>'), 'foobar'); 41 42 $highlighter = new sfLuceneHighlighterHTMLPart($given); 43 $highlighter->addKeywords(array($keyword)); 44 $highlighter->highlight(); 45 46 $t->is($highlighter->export(), $expected, '->highlight() handles entities correctly'); plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterHTMLTest.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(2, new lime_output_color()); 19 $t = new limeade_test(2, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $xml = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterStringTest.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(8, new lime_output_color()); 19 $t = new limeade_test(8, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $keywords = array(new sfLuceneHighlighterKeywordNamed(new sfLuceneHighlighterMarkerUppercase, 'foobar'), new sfLuceneHighlighterKeywordNamed(new sfLuceneHighlighterMarkerSprint('"%s"'), 'foobarbaz')); plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterXHTMLPartTest.php
r6883 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(2, new lime_output_color()); 19 $t = new limeade_test(3, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $given = '<p>This is part of a document, dedicated to foobar.</p><p>Look, a foobar</p>'; 22 23 24 $expected = '<p>This is part of a document, dedicated to <h>foobar</h>.</p><p>Look, a <h>foobar</h></p>'; 24 25 … … 32 33 33 34 $given = '<html><body><p>This is part of a document, dedicated to foobar.</p></body></html>'; 34 35 35 $expected = '<html><body><p>This is part of a document, dedicated to <h>foobar</h>.</p></body></html>'; 36 36 … … 42 42 43 43 $t->is($highlighter->export(), $expected, '->highlight() does not fail if it is really a full document'); 44 45 $given = '<p>This is pàrt of a document, dedicated to foobar.</p>'; 46 $expected = '<p>This is pàrt of a document, dedicated to <h>foobar</h>.</p>'; 47 48 $keyword = new sfLuceneHighlighterKeywordNamed(new sfLuceneHighlighterMarkerSprint('<h>%s</h>'), 'foobar'); 49 50 $highlighter = new sfLuceneHighlighterXHTMLPart($given); 51 $highlighter->addKeywords(array($keyword)); 52 $highlighter->highlight(); 53 54 $t->is($highlighter->export(), $expected, '->highlight() handles entities correctly'); plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterXHTMLTest.php
r6891 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(4, new lime_output_color()); 19 $t = new limeade_test(4, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $xml = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> plugins/sfLucenePlugin/branches/1.1/test/unit/highlighter/sfLuceneHighlighterXMLTest.php
r6891 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(6, new lime_output_color()); 19 $t = new limeade_test(8, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 20 22 21 23 $xml = '<?xml version="1.0"?> … … 104 106 $t->is($highlighter->export(), $expected, '->highlight() handles multiple keywords'); 105 107 108 $xml = '<?xml version="1.0"?> 109 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/2000/REC-xhtml1-200000126/DTD/xhtml1-transitional.dtd"> 110 <root> 111 <child>hello & bazó</child> 112 <child>i am foobar</child> 113 </root> 114 '; 115 116 $expected = '<?xml version="1.0"?> 117 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/2000/REC-xhtml1-200000126/DTD/xhtml1-transitional.dtd"> 118 <root> 119 <child>hello & <s>baz</s>ó</child> 120 <child>i am <h>foobar</h></child> 121 </root> 122 '; 123 124 $highlighter = new sfLuceneHighlighterXML($xml); 125 $highlighter->addKeywords(array($keyword, $keyword2)); 126 $highlighter->highlight(); 127 128 $t->is($highlighter->export(), $expected, '->highlight() handles entities correctly'); 129 130 $xml = '<?xml version="1.0"?> 131 <root> 132 <child>hellÆ bäz</child> 133 <child>i am fööbär</child> 134 </root> 135 '; 136 137 $expected = '<?xml version="1.0"?> 138 <root> 139 <child>hellÆ <s>bäz</s></child> 140 <child>i am <h>fööbär</h></child> 141 </root> 142 '; 143 144 $highlighter = new sfLuceneHighlighterXML($xml); 145 $highlighter->addKeywords(array($keyword, $keyword2)); 146 $highlighter->highlight(); 147 148 //$t->is($highlighter->export(), $expected, '->highlight() handles UTF8 characters correctly'); 149 $t->todo('->highlight() handles UTF8 characters correctly (pending elegant solution)'); 150 106 151 try { 107 152 $h = new sfLuceneHighlighterXML('<foo>&ddd;<foo></baz></bar>'); plugins/sfLucenePlugin/branches/1.1/test/unit/indexer/sfLuceneIndexerFactoryTest.php
r6703 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 16 16 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 require dirname(__FILE__) . '/../../bin/AllFakeModels.php';19 18 20 19 class Foo { } … … 23 22 class sfLuceneActionIndexer { } 24 23 25 $t = new lime_test(14, new lime_output_color()); 24 $t = new limeade_test(14, limeade_output::get()); 25 $limeade = new limeade_sf($t); 26 $app = $limeade->bootstrap(); 27 28 $luceneade = new limeade_lucene($limeade); 29 $luceneade->configure()->clear_sandbox()->load_models(); 26 30 27 31 $search = sfLucene::getInstance('testLucene'); plugins/sfLucenePlugin/branches/1.1/test/unit/indexer/sfLucenePropelIndexerHandlerTest.php
r6703 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 16 16 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 require dirname(__FILE__) . '/../../bin/AllFakeModels.php'; 18 19 $t = new limeade_test(3, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 22 23 $luceneade = new limeade_lucene($limeade); 24 $luceneade->configure()->clear_sandbox()->load_models(); 19 25 20 26 class FooIndexer extends sfLucenePropelIndexerHandler … … 27 33 } 28 34 } 29 30 $t = new lime_test(3, new lime_output_color());31 35 32 36 $search = sfLucene::getInstance('testLucene', 'en'); plugins/sfLucenePlugin/branches/1.1/test/unit/indexer/sfLucenePropelIndexerTest.php
r6771 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 16 16 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 require dirname(__FILE__) . '/../../bin/AllFakeModels.php'; 18 19 $t = new limeade_test(64, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 22 23 $luceneade = new limeade_lucene($limeade); 24 $luceneade->configure()->clear_sandbox()->load_models(); 19 25 20 26 class Foo { } … … 30 36 } 31 37 32 $t = new lime_test(64, new lime_output_color());33 34 38 $lucene = sfLucene::getInstance('testLucene', 'en'); 35 39 $model = new FakeForum; … … 283 287 $t->is($doc->sfl_categories_cache, serialize(explode(' ', $doc->sfl_category)), '->insert() configures categories cache correctly'); 284 288 285 $t->is($lucene->getCategories ()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count');286 287 configure_i18n(true,'en');289 $t->is($lucene->getCategoriesHarness()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count'); 290 291 $app->i18n()->setup('en'); 288 292 289 293 $indexer->delete(); … … 295 299 $t->is($doc->sfl_categories_cache, serialize(explode(' ', $doc->sfl_category)), '->insert() configures categories cache correctly with i18n on'); 296 300 297 $t->is($lucene->getCategories ()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count with i18n on');298 299 configure_i18n(false);301 $t->is($lucene->getCategoriesHarness()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count with i18n on'); 302 303 $app->i18n()->teardown(); 300 304 301 305 $h->set('categories', 'Forum'); … … 309 313 $t->is($doc->sfl_categories_cache, serialize(explode(' ', $doc->sfl_category)), '->insert() configures categories cache correctly if just a string'); 310 314 311 $t->is($lucene->getCategories ()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count if just a string');315 $t->is($lucene->getCategoriesHarness()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count if just a string'); 312 316 313 317 $h->set('categories', array('Forum', '%title%')); … … 323 327 $t->is($doc->sfl_categories_cache, serialize(array('Forum','foobar')), '->insert() configures categories cache correctly with a callback'); 324 328 325 $t->is($lucene->getCategories ()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count for first category');326 $t->is($lucene->getCategories ()->getCategory('foobar')->getCount(), 1, '->insert() updated category database count for second category');329 $t->is($lucene->getCategoriesHarness()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count for first category'); 330 $t->is($lucene->getCategoriesHarness()->getCategory('foobar')->getCount(), 1, '->insert() updated category database count for second category'); 327 331 328 332 $indexer->delete(); … … 356 360 $t->is($doc->sfl_categories_cache, serialize(array('Forum','Strings!')), '->insert() configures categories cache correctly with a object-returning callback'); 357 361 358 $t->is($lucene->getCategories ()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count for first category with object-returning callback');359 $t->is($lucene->getCategories ()->getCategory('Strings!')->getCount(), 1, '->insert() updated category database count for second category with object-returning callback');362 $t->is($lucene->getCategoriesHarness()->getCategory('Forum')->getCount(), 1, '->insert() updated category database count for first category with object-returning callback'); 363 $t->is($lucene->getCategoriesHarness()->getCategory('Strings!')->getCount(), 1, '->insert() updated category database count for second category with object-returning callback'); 360 364 361 365 $h->remove('categories'); … … 388 392 $t->is($lucene->numDocs(), 0, '->delete() deletes all matching documents in the index'); 389 393 390 $lucene->getCategories ()->getCategory('Cat1')->add(5);394 $lucene->getCategoriesHarness()->getCategory('Cat1')->add(5); 391 395 392 396 $h->set('categories', array('Cat1')); 393 397 $indexer->insert(); 394 398 $lucene->commit(); 395 $count = $lucene->getCategories ()->getCategory('Cat1')->getCount();396 $indexer->delete(); 397 398 $t->is($lucene->getCategories ()->getCategory('Cat1')->getCount(), $count - 1, '->delete() updates the category database count');399 400 $indexer->insert(); 401 $count = $lucene->getCategories ()->getCategory('Cat1')->getCount();399 $count = $lucene->getCategoriesHarness()->getCategory('Cat1')->getCount(); 400 $indexer->delete(); 401 402 $t->is($lucene->getCategoriesHarness()->getCategory('Cat1')->getCount(), $count - 1, '->delete() updates the category database count'); 403 404 $indexer->insert(); 405 $count = $lucene->getCategoriesHarness()->getCategory('Cat1')->getCount(); 402 406 $h->set('categories', array('Cat2')); 403 407 $indexer->delete(); 404 408 405 $t->is($lucene->getCategories ()->getCategory('Cat1')->getCount(), $count - 1, '->delete() updates category count that it was indexed with if categories have changed');406 $t->is($lucene->getCategories ()->getCategory('Cat2')->getCount(), 0, '->delete() does not update new category count if categories have changed');409 $t->is($lucene->getCategoriesHarness()->getCategory('Cat1')->getCount(), $count - 1, '->delete() updates category count that it was indexed with if categories have changed'); 410 $t->is($lucene->getCategoriesHarness()->getCategory('Cat2')->getCount(), 0, '->delete() does not update new category count if categories have changed'); 407 411 408 412 $t->diag('testing ->save()'); plugins/sfLucenePlugin/branches/1.1/test/unit/results/sfLuceneActionResultTest.php
r6685 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(1, new lime_output_color()); 19 $t = new limeade_test(1, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 22 23 $luceneade = new limeade_lucene($limeade); 24 $luceneade->configure()->clear_sandbox(); 20 25 21 26 $lucene = sfLucene::getInstance('testLucene'); plugins/sfLucenePlugin/branches/1.1/test/unit/results/sfLuceneModelResultTest.php
r6685 r7108 2 2 /* 3 3 * This file is part of the sfLucenePlugin package 4 * (c) 2007 Carl Vondrick <carlv@carlsoft.net>4 * (c) 2007 - 2008 Carl Vondrick <carl@carlsoft.net> 5 5 * 6 6 * For the full copyright and license information, please view the LICENSE … … 17 17 require dirname(__FILE__) . '/../../bootstrap/unit.php'; 18 18 19 $t = new lime_test(12, new lime_output_color()); 19 $t = new limeade_test(12, limeade_output::get()); 20 $limeade = new limeade_sf($t); 21 $app = $limeade->bootstrap(); 22 23 $luceneade = new limeade_lucene($limeade); 24 $luceneade->configure()->clea