1C-Bitrix 25.700.0
Загрузка...
Поиск...
Не найдено
full_text.php
См. документацию.
1<?php
2
4{
8 protected static $instance = null;
9
15 public static function getInstance()
16 {
17 if (!isset(static::$instance))
18 {
19 $full_text_engine = COption::GetOptionString('search', 'full_text_engine');
20 if ($full_text_engine === 'sphinx')
21 {
22 self::$instance = new CSearchSphinx;
23 self::$instance->connect(
24 COption::GetOptionString('search', 'sphinx_connection'),
25 COption::GetOptionString('search', 'sphinx_index_name')
26 );
27 }
28 elseif ($full_text_engine === 'opensearch')
29 {
30 require_once($_SERVER["DOCUMENT_ROOT"]."/bitrix/modules/main/classes/general/backup.php");
31 self::$instance = new CSearchOpenSearch;
32 self::$instance->connect(
33 COption::GetOptionString('search', 'opensearch_connection'),
34 COption::GetOptionString('search', 'opensearch_user'),
35 CPasswordStorage::Get('search@opensearch_password'),
36 COption::GetOptionString('search', 'opensearch_index'),
37 );
38 }
39 elseif ($full_text_engine === 'mysql')
40 {
41 self::$instance = new CSearchMysql;
42 self::$instance->connect();
43 }
44 elseif ($full_text_engine === 'pgsql')
45 {
46 self::$instance = new CSearchPgsql;
47 self::$instance->connect();
48 }
49 else
50 {
51 self::$instance = new CSearchStemTable();
52 }
53 }
54 return static::$instance;
55 }
56
57 public function connect($connectionString)
58 {
59 return true;
60 }
61
62 public function truncate()
63 {
64 }
65
66 public function deleteById($ID)
67 {
68 }
69
70 public function replace($ID, $arFields)
71 {
72 }
73
74 public function update($ID, $arFields)
75 {
76 }
77
78 public function search($arParams, $aSort, $aParamsEx, $bTagsCloud)
79 {
80 return false;
81 }
82
83 function searchTitle($phrase = '', $arPhrase = [], $nTopCount = 5, $arParams = [], $bNotFilter = false, $order = '')
84 {
85 return false;
86 }
87
88 public function getErrorText()
89 {
90 return '';
91 }
92
93 public function getErrorNumber()
94 {
95 return 0;
96 }
97
98 function getRowFormatter()
99 {
100 return null;
101 }
102}
103
105{
106 function format($r)
107 {
108 return $r;
109 }
110}
$arParams
Определения access_dialog.php:21
static Get($strName)
Определения backup.php:817
Определения full_text.php:105
format($r)
Определения full_text.php:106
Определения full_text.php:4
searchTitle($phrase='', $arPhrase=[], $nTopCount=5, $arParams=[], $bNotFilter=false, $order='')
Определения full_text.php:83
getErrorNumber()
Определения full_text.php:93
update($ID, $arFields)
Определения full_text.php:74
connect($connectionString)
Определения full_text.php:57
getErrorText()
Определения full_text.php:88
getRowFormatter()
Определения full_text.php:98
static getInstance()
Определения full_text.php:15
static $instance
Определения full_text.php:8
deleteById($ID)
Определения full_text.php:66
truncate()
Определения full_text.php:62
replace($ID, $arFields)
Определения full_text.php:70
search($arParams, $aSort, $aParamsEx, $bTagsCloud)
Определения full_text.php:78
Определения mysql.php:5
connect($connectionString='')
Определения mysql.php:9
Определения opensearch.php:5
connect($connectionString, $user='', $password='', $indexName='', $ignoreErrors=false, $siteAnalyzerMap='')
Определения opensearch.php:17
Определения pgsql.php:5
connect($connectionString='')
Определения pgsql.php:9
Определения sphinx.php:5
connect($connectionIndex, $indexName='', $ignoreErrors=false)
Определения sphinx.php:44
Определения stemtable.php:5
$arFields
Определения dblapprove.php:5
$arPhrase
Определения get_search.php:37
if($ajaxMode) $ID
Определения get_user.php:27
$_SERVER["DOCUMENT_ROOT"]
Определения cron_frame.php:9
$order
Определения payment.php:8
if( $daysToExpire >=0 &&$daysToExpire< 60 elseif)( $daysToExpire< 0)
Определения prolog_main_admin.php:393