Engine 'used' for index.
(Not really used, its just the information stored to increase compatibility with mysql.)

@return IndexEngine
559843
public function getEngine()
    {
        $rawEngine = $this->data[193];
        $engine = ord($rawEngine);

        if ($engine <= 0) {
            $engine = IndexEngine::BTREE;
        }

        return IndexEngine::getByValue($engine);
    }
526518
public function getCreateIndexSQL(Index $index, $table)
    {
        return parent::getCreateIndexSQL($index, $table) . $this->getAdvancedIndexOptionsSQL($index);
    }
214786
public function getMySQL()
    {
        if (null == $this->mysql_unserialized && null !== $this->mysql) {
            $this->mysql_unserialized = unserialize($this->mysql);
        }

        return $this->mysql_unserialized;
    }
1166384
public function IndexBy()
    {
        $this->match(Lexer::T_INDEX);
        $this->match(Lexer::T_BY);
        $pathExpr = $this->StateFieldPathExpression();

        // Add the INDEX BY info to the query component
        $this->queryComponents[$pathExpr->identificationVariable]['map'] = $pathExpr->field;

        return new AST\IndexBy($pathExpr);
    }
325308
public function actionIndex()
    {
        if (!$this->hasAccess()) {
            return $this->redirect(['login']);
        }
        
        foreach ($this->module->assetFiles as $class) {
            $this->registerAsset($class);
        }

        return $this->render('index', [
            'title' => 'Styleguide',
            'showDomain' => true,
            'styleguide' => $this->extractElementsFromComponent()
        ]);
    }
461311
public function InitializeIndexer()
    {
        $bWorkToDo = true;
        if (!$this->bRegenerateCompleteIndex) {
            // drop index
            $query = "UPDATE shop_search_reindex_queue SET `processing` = '1'";
            MySqlLegacySupport::getInstance()->query($query);
            $query = "SELECT COUNT(*) AS reccount FROM shop_search_reindex_queue WHERE `processing` = '1'";
            $aCount = MySqlLegacySupport::getInstance()->fetch_assoc(MySqlLegacySupport::getInstance()->query($query));
            if ($aCount['reccount'] > 0) {
                $query = "SHOW TABLES LIKE '_index_%'";
                $tRes = MySqlLegacySupport::getInstance()->query($query);
                while ($aIndexTable = MySqlLegacySupport::getInstance()->fetch_row($tRes)) {
                    $query = "DELETE FROM {$aIndexTable[0]} USING {$aIndexTable[0]}, shop_search_reindex_queue WHERE {$aIndexTable[0]}.`shop_article_id`= shop_search_reindex_queue.object_id AND `shop_search_reindex_queue`.`processing`='1' ";
                    MySqlLegacySupport::getInstance()->query($query);
                }
                $sQuery = "DELETE FROM shop_search_reindex_queue WHERE `processing` = '1' AND `action` = 'delete'";
                MySqlLegacySupport::getInstance()->query($sQuery);

                $query = "SELECT COUNT(*) AS reccount FROM shop_search_reindex_queue WHERE `processing` = '1'";
                $aCount = MySqlLegacySupport::getInstance()->fetch_assoc(MySqlLegacySupport::getInstance()->query($query));
                if (0 == $aCount['reccount']) {
                    $bWorkToDo = false;
                }
            } else {
                $bWorkToDo = false;
            }
        }
        if ($bWorkToDo) {
            $this->aTablesToProcess = array();
            $aData = $this->sqlData;
            $aData['started'] = date('Y-m-d H:i:s');
            $aData['completed'] = date('0000-00-00 00:00:00');
            $iTotalRows = 0;
            $query = 'SELECT shop_search_query.*
                    FROM shop_search_query
              INNER JOIN shop_search_field_weight ON shop_search_query.id = shop_search_field_weight.shop_search_query_id
                GROUP BY shop_search_query.id
                 ';
            $oIndexQueries = &TdbShopSearchQueryList::GetList($query);
            while ($oIndexQuery = &$oIndexQueries->Next()) {
                $oIndexQuery->StartIndex($this->bRegenerateCompleteIndex);
                $iNumberOfItems = $oIndexQuery->NumberOfRecordsLeftToIndex();
                if ($iNumberOfItems > 0) {
                    $iTotalRows += $iNumberOfItems;
                    $this->aTablesToProcess[] = $oIndexQuery->id;
                }
            }
            $aData['total_rows_to_process'] = $iTotalRows;
            $sTmp = serialize($this->aTablesToProcess);
            $aData['processdata'] = $sTmp;

            $this->LoadFromRow($aData);
            $this->AllowEditByAll(true);
            $this->Save();

            $this->CommitProcessData();

            $this->CreateIndexTables();
        }
    }
545328
protected function getCurrentSQL() {
        $cloneQuery = clone $this->query;
        $cloneQuery = $this->loadElements($cloneQuery);
        return $cloneQuery->compile();
    }
1189125
public function getIndex(): Index
    {
        $index = $this->searchClient->findIndex($this->getIndexName());
        $index->setSettingsKey($this->searchClient->getIndexName());

        return $index;
    }
281185
public function getEngine()
    {
        if (null === $this->engine) {
            $this->setEngine(TemplateFactory::getEngine());
        }
        return $this->engine;
    }
738303
public function getIndex() : ?int 
    {
        if ( ! $this->hasIndex()) {
            $this->setIndex($this->getDefaultIndex());
        }
        return $this->index;
    }
1302058
public function count()
    {
        if ($this->count === null) {
            $this->count = $this->elasticSearchQuery->getQueryBuilder()->count();
        }

        return $this->count;
    }
552734
public static function getEngine()
    {
        if (self::$nb_engine === null) {
            self::$nb_engine = new CNabuEngine();
            self::$nb_engine->init();
        }

        return self::$nb_engine;
    }
267400
public function prune($indexEngineIndex = null)
    {
        if ($indexEngineIndex) {
            $this->addUsingAlias(IndexEngineIndexTableMap::ID, $indexEngineIndex->getId(), Criteria::NOT_EQUAL);
        }

        return $this;
    }
643833
public function SQL() {
      if(is_null($this->_SQL)) {
         $Name = $this->Engine . 'Driver';
         $this->_SQL = Gdn::Factory($Name);
         $this->_SQL->Database = $this;
      }
      
      return $this->_SQL;
   }
563297
protected function bindIndex()
    {
        $this->app->bind('iverberk.larasearch.index', function ($app, $params)
        {
            $name = isset($params['name']) ? $params['name'] : '';

            return new Index($params['proxy'], $name);
        });
    }
1372273
public function actionFillIndex()
    {
        try {
            $this->client->ping();
        } catch (NoNodesAvailableException $e) {
            $this->stderr($e->getMessage() . ', maybe you first need to configure and run elasticsearch' . PHP_EOL);
            return;
        }
        /** @var HasProperties | PropertiesTrait $model */
        foreach ($this->applicables as $indexName => $model) {
            if (true === $this->client->indices()->exists(['index' => $indexName])) {
                $this->client->indices()->delete(['index' => $indexName]);
            }
            $config = self::prepareIndexConfig();
            $config['index'] = $indexName;
            $response = $this->client->indices()->create($config);
            if (true === isset($response['acknowledged']) && $response['acknowledged'] == 1) {
                foreach (self::$storage as $className => $id) {
                    $indexData = self::prepareIndexData($model, $indexName, $className, $id);
                    if (false === empty($indexData['body'])) {
                        $this->client->bulk($indexData);
                    }
                }
            }
        }
    }
756458
public function index(string $indexName = null)
    {
        $this->indexName = $indexName ?? $this->tableName . '_' . $this->name . '_index';

        return $this;
    }