Submit
Path:
~
/
/
opt
/
psa
/
admin
/
plib
/
vendor
/
plesk
/
zendsearch
/
library
/
ZendSearch
/
Lucene
/
Analysis
/
Analyzer
/
File Content:
AbstractAnalyzer.php
<?php /** * Zend Framework (http://framework.zend.com/) * * @link http://github.com/zendframework/zf2 for the canonical source repository * @copyright Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License * @package Zend_Search */ namespace ZendSearch\Lucene\Analysis\Analyzer; use ZendSearch\Lucene\Analysis\Analyzer\AnalyzerInterface as LuceneAnalyzer; /** * General analyzer implementation. * * @category Zend * @package Zend_Search_Lucene * @subpackage Analysis */ abstract class AbstractAnalyzer implements LuceneAnalyzer { /** * Input string * * @var string */ protected $_input = null; /** * Input string encoding * * @var string */ protected $_encoding = ''; /** * Tokenize text to a terms * Returns array of \ZendSearch\Lucene\Analysis\Token objects * * Tokens are returned in UTF-8 (internal Zend_Search_Lucene encoding) * * @param string $data * @return array */ public function tokenize($data, $encoding = '') { $this->setInput($data, $encoding); $tokenList = array(); while (($nextToken = $this->nextToken()) !== null) { $tokenList[] = $nextToken; } return $tokenList; } /** * Tokenization stream API * Set input * * @param string $data */ public function setInput($data, $encoding = '') { $this->_input = $data; $this->_encoding = $encoding; $this->reset(); } }
Submit
FILE
FOLDER
INFO
Name
Size
Permission
Action
Common
---
0755
AbstractAnalyzer.php
1631 bytes
0644
Analyzer.php
1479 bytes
0644
AnalyzerInterface.php
1366 bytes
0644
N4ST4R_ID | Naxtarrr