Skip to content
This repository was archived by the owner on Mar 4, 2025. It is now read-only.

Commit 3c9f7a7

Browse files
1.8
* [+] showMeta moved to SphinxToolkitHelper
1 parent 805af9b commit 3c9f7a7

File tree

3 files changed

+14
-13
lines changed

3 files changed

+14
-13
lines changed

interfaces/SphinxToolkitFoolzInterface.php

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -133,12 +133,4 @@ public static function rt_RebuildAbstractIndex(PDO $pdo_connection, string $sql_
133133
*/
134134
public static function getInstance($connection);
135135

136-
/**
137-
* Возвращает META-информацию (после запроса)
138-
*
139-
* @throws ConnectionException
140-
* @throws DatabaseException
141-
* @throws SphinxQLException
142-
*/
143-
public static function showMeta();
144136
}

src/SphinxToolkit.php

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -523,11 +523,6 @@ public static function rt_RebuildAbstractIndex(PDO $pdo_connection, string $sql_
523523
return $total_updated;
524524
}
525525

526-
public static function showMeta()
527-
{
528-
return (new Helper(self::$spql_connection))->showMeta()->execute()->fetchAllAssoc();
529-
}
530-
531526
/**
532527
*
533528
* @param string $index_name

traits/SphinxToolkitHelper.php

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
namespace Arris\Toolkit;
44

5+
use Foolz\SphinxQL\Drivers\ConnectionInterface;
6+
use Foolz\SphinxQL\Helper;
57
use PDO;
68

79
/**
@@ -233,4 +235,16 @@ public static function EmulateBuildExcerpts($source, $needle, $options)
233235
return $target;
234236
} // EmulateBuildExcerpts
235237

238+
/**
239+
*
240+
* @param ConnectionInterface $connection
241+
* @throws \Foolz\SphinxQL\Exception\ConnectionException
242+
* @throws \Foolz\SphinxQL\Exception\DatabaseException
243+
* @throws \Foolz\SphinxQL\Exception\SphinxQLException
244+
*/
245+
public static function showMeta(ConnectionInterface $connection)
246+
{
247+
(new Helper($connection))->showMeta()->execute()->fetchAllAssoc();
248+
}
249+
236250
}

0 commit comments

Comments
 (0)