TermInfo.php 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. <?php
  2. /**
  3. * Zend Framework
  4. *
  5. * LICENSE
  6. *
  7. * This source file is subject to the new BSD license that is bundled
  8. * with this package in the file LICENSE.txt.
  9. * It is also available through the world-wide-web at this URL:
  10. * http://framework.zend.com/license/new-bsd
  11. * If you did not receive a copy of the license and are unable to
  12. * obtain it through the world-wide-web, please send an email
  13. * to license@zend.com so we can send you a copy immediately.
  14. *
  15. * @category Zend
  16. * @package Zend_Search_Lucene
  17. * @subpackage Index
  18. * @copyright Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
  19. * @license http://framework.zend.com/license/new-bsd New BSD License
  20. * @version $Id$
  21. */
  22. /**
  23. * A Zend_Search_Lucene_Index_TermInfo represents a record of information stored for a term.
  24. *
  25. * @category Zend
  26. * @package Zend_Search_Lucene
  27. * @subpackage Index
  28. * @copyright Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
  29. * @license http://framework.zend.com/license/new-bsd New BSD License
  30. */
  31. class Zend_Search_Lucene_Index_TermInfo
  32. {
  33. /**
  34. * The number of documents which contain the term.
  35. *
  36. * @var integer
  37. */
  38. public $docFreq;
  39. /**
  40. * Data offset in a Frequencies file.
  41. *
  42. * @var integer
  43. */
  44. public $freqPointer;
  45. /**
  46. * Data offset in a Positions file.
  47. *
  48. * @var integer
  49. */
  50. public $proxPointer;
  51. /**
  52. * ScipData offset in a Frequencies file.
  53. *
  54. * @var integer
  55. */
  56. public $skipOffset;
  57. /**
  58. * Term offset of the _next_ term in a TermDictionary file.
  59. * Used only for Term Index
  60. *
  61. * @var integer
  62. */
  63. public $indexPointer;
  64. public function __construct($docFreq, $freqPointer, $proxPointer, $skipOffset, $indexPointer = null)
  65. {
  66. $this->docFreq = $docFreq;
  67. $this->freqPointer = $freqPointer;
  68. $this->proxPointer = $proxPointer;
  69. $this->skipOffset = $skipOffset;
  70. $this->indexPointer = $indexPointer;
  71. }
  72. }