public function testMath() { $this->assertEquals(ESphinxMatch::ALL, SPH_MATCH_ALL); $this->assertEquals(ESphinxMatch::ANY, SPH_MATCH_ANY); $this->assertEquals(ESphinxMatch::PHRASE, SPH_MATCH_PHRASE); $this->assertEquals(ESphinxMatch::BOOLEAN, SPH_MATCH_BOOLEAN); $this->assertEquals(ESphinxMatch::EXTENDED, SPH_MATCH_EXTENDED); $this->assertEquals(ESphinxMatch::FULLSCAN, SPH_MATCH_FULLSCAN); $this->assertEquals(ESphinxMatch::EXTENDED2, SPH_MATCH_EXTENDED2); $this->assertCount(7, ESphinxMatch::items()); }
protected function applyMatchMode($mode) { $mode = (int) $mode; if (!ESphinxMatch::isValid($mode)) { throw new ESphinxException("Match mode {$mode} is not defined"); } $this->sphinxClient->SetMatchMode($mode); }