~ubuntu-branches/ubuntu/jaunty/moodle/jaunty

« back to all changes in this revision

Viewing changes to search/Zend/Search/Lucene/Search/Weight/Phrase.php

  • Committer: Bazaar Package Importer
  • Author(s): Jordan Mantha, Matt Oquist
  • Date: 2009-02-25 15:16:22 UTC
  • mfrom: (1.1.11 upstream)
  • Revision ID: james.westby@ubuntu.com-20090225151622-0ekt1liwhv2obfza
Tags: 1.9.4.dfsg-0ubuntu1
* Merge with Debian git (Closes LP: #322961, #239481, #334611):
  - use Ubuntu's smarty lib directory for linking
  - use internal yui library 
  - add update-notifier support back in

[Matt Oquist]
  * renamed prerm script
  * significantly rewrote postinst and other maintainer scripts to improve
    user experience and package maintainability
    (Closes LP: #225662, #325450, #327843, #303078, #234609)

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
 * @category   Zend
16
16
 * @package    Zend_Search_Lucene
17
17
 * @subpackage Search
18
 
 * @copyright  Copyright (c) 2006 Zend Technologies USA Inc. (http://www.zend.com)
 
18
 * @copyright  Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
19
19
 * @license    http://framework.zend.com/license/new-bsd     New BSD License
20
20
 */
21
21
 
30
30
 * @category   Zend
31
31
 * @package    Zend_Search_Lucene
32
32
 * @subpackage Search
33
 
 * @copyright  Copyright (c) 2006 Zend Technologies USA Inc. (http://www.zend.com)
 
33
 * @copyright  Copyright (c) 2005-2008 Zend Technologies USA Inc. (http://www.zend.com)
34
34
 * @license    http://framework.zend.com/license/new-bsd     New BSD License
35
35
 */
36
36
class Zend_Search_Lucene_Search_Weight_Phrase extends Zend_Search_Lucene_Search_Weight
38
38
    /**
39
39
     * IndexReader.
40
40
     *
41
 
     * @var Zend_Search_Lucene
 
41
     * @var Zend_Search_Lucene_Interface
42
42
     */
43
43
    private $_reader;
44
44
 
50
50
    private $_query;
51
51
 
52
52
    /**
53
 
     * Weight value
54
 
     *
55
 
     * @var float
56
 
     */
57
 
    private $_value;
58
 
 
59
 
    /**
60
53
     * Score factor
61
54
     *
62
55
     * @var float
64
57
    private $_idf;
65
58
 
66
59
    /**
67
 
     * Normalization factor
68
 
     *
69
 
     * @var float
70
 
     */
71
 
    private $_queryNorm;
72
 
 
73
 
 
74
 
    /**
75
 
     * Query weight
76
 
     *
77
 
     * @var float
78
 
     */
79
 
    private $_queryWeight;
80
 
 
81
 
 
82
 
    /**
83
60
     * Zend_Search_Lucene_Search_Weight_Phrase constructor
84
61
     *
85
62
     * @param Zend_Search_Lucene_Search_Query_Phrase $query
86
 
     * @param Zend_Search_Lucene $reader
 
63
     * @param Zend_Search_Lucene_Interface           $reader
87
64
     */
88
 
    public function __construct(Zend_Search_Lucene_Search_Query_Phrase $query, Zend_Search_Lucene $reader)
 
65
    public function __construct(Zend_Search_Lucene_Search_Query_Phrase $query,
 
66
                                Zend_Search_Lucene_Interface           $reader)
89
67
    {
90
68
        $this->_query  = $query;
91
69
        $this->_reader = $reader;
92
70
    }
93
71
 
94
 
 
95
 
    /**
96
 
     * The weight for this query
97
 
     *
98
 
     * @return float
99
 
     */
100
 
    public function getValue()
101
 
    {
102
 
        return $this->_value;
103
 
    }
104
 
 
105
 
 
106
72
    /**
107
73
     * The sum of squared weights of contained query clauses.
108
74
     *