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.
Calculate query weights and build query scorers.
A Weight is constructed by a query Query->createWeight(). The sumOfSquaredWeights() method is then called on the top-level query to compute the query normalization factor Similarity->queryNorm(float). This factor is then passed to normalize(float). At this point the weighting is complete.

__construct(
\Zend_Search_Lucene_Search_Query_Phrase $query, \Zend_Search_Lucene_Interface $reader
)
:
void
Zend_Search_Lucene_Search_Weight_Phrase constructor
Name | Type | Description |
---|---|---|
$query | \Zend_Search_Lucene_Search_Query_Phrase | |
$reader | \Zend_Search_Lucene_Interface |

getValue(
)
:
float
The weight for this query.
Inherited from: \Zend_Search_Lucene_Search_Weight::getValue()Type | Description |
---|---|
float |

normalize(
float $queryNorm
)
:
void
Assigns the query normalization factor to this.
Name | Type | Description |
---|---|---|
$queryNorm | float |