Passed
Push — master ( eff61e...76df74 )
by Gordon
02:24
created

IndexCreator::getIndexStoredFields()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 1
c 1
b 0
f 0
dl 0
loc 3
rs 10
cc 1
nc 1
nop 0
1
<?php declare(strict_types = 1);
2
3
namespace Suilven\FreeTextSearch\Tests\Mock;
4
5
// @phpcs:disable SlevomatCodingStandard.Functions.UnusedParameter.UnusedParameter
6
class IndexCreator extends \Suilven\FreeTextSearch\Base\IndexCreator implements
7
    \Suilven\FreeTextSearch\Interfaces\IndexCreator
8
{
9
10
    /** @var string */
11
    private static $indexName;
12
13
    public function createIndex(string $indexName): void
14
    {
15
        self::$indexName = $indexName;
16
    }
17
18
19
    /** @return array<string> */
20
    public function getIndexStoredFields(): array
21
    {
22
        return $this->getStoredFields('sitetree');
23
    }
24
25
26
    public static function getIndexName(): string
27
    {
28
        return self::$indexName;
29
    }
30
}
31