Zend Framework
LICENSE
This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.
Zend_Search_Lucene_Index_SegmentWriter_DocumentWriter $_currentSegment = 'null'Current segment to add documents
DetailsZend_Search_Lucene_Storage_Directory $_directory = 'null'File system adapter.
Detailsarray $_indexExtensions = 'array'List of indexfiles extensions
Detailsarray $_newSegments = 'array'List of the segments, created by index writer Array of Zend_Search_Lucene_Index_SegmentInfo objects
Detailsarray $_segmentInfos = ''Array of Zend_Search_Lucene_Index_SegmentInfo objects for this index.
It's a reference to the corresponding Zend_Search_Lucene::$_segmentInfos array
Detailsarray $_segmentsToDelete = 'array'List of segments to be deleted on commit
Detailsinteger $_targetFormatVersion = ''Index target format version
Detailsinteger $_versionUpdate = '0'Changes counter.
Detailsinteger $maxBufferedDocs = '10'Number of documents required before the buffered in-memory documents are written into a new Segment
Default value is 10
Detailsinteger $maxMergeDocs = 'PHP_INT_MAX'Largest number of documents ever merged by addDocument().
Small values (e.g., less than 10,000) are best for interactive indexing, as this limits the length of pauses while indexing to a few seconds. Larger values are best for batched indexing and speedier searches.
Default value is PHP_INT_MAX
Detailsinteger $mergeFactor = '10'Determines how often segment indices are merged by addDocument().
With smaller values, less RAM is used while indexing, and searches on unoptimized indices are faster, but indexing speed is slower.
With larger values, more RAM is used during indexing, and while searches on unoptimized indices are slower, indexing is faster.
Thus larger values (> 10) are best for batch index creation, and smaller values (< 10) for indices that are interactively maintained.
Default value is 10
Details__construct(
Zend_Search_Lucene_Storage_Directory $directory, array $segmentInfos, integer $targetFormatVersion
)
:
Open the index for writing
Details_hasAnythingToMerge(
)
:
booleanCheck if we have anything to merge
Details_maybeMergeSegments(
)
:
Merge segments if necessary
Details_mergeSegments(
array $segments
)
:
Merge specified segments
$segments is an array of SegmentInfo objects
Details_newSegmentName(
)
:
stringGet name for new segment
Details_updateSegments(
)
:
Update segments file by adding current segment to a list
DetailsaddDocument(
Zend_Search_Lucene_Document $document
)
:
Adds a document to this index.
DetailsaddIndexes(
array $readers
)
:
voidMerges the provided indexes into this index.
Detailscommit(
)
:
Commit current changes
DetailscreateIndex(
Zend_Search_Lucene_Storage_Directory $directory, integer $generation, integer $nameCount
)
:
Create empty index
Detailsoptimize(
)
:
booleanMerges all segments together into new one
Returns true on success and false if another optimization or auto-optimization process is running now
Details