Fuzzy   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 40
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
dl 0
loc 40
ccs 6
cts 6
cp 1
rs 10
c 0
b 0
f 0
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A transpositions() 0 5 1
A fuzziness() 0 5 1
1
<?php
2
/*
3
 * This file is part of PhpStorm.
4
 *
5
 * (c) PHPinnacle Team <[email protected]>
6
 *
7
 * For the full copyright and license information, please view the LICENSE
8
 * file that was distributed with this source code.
9
 */
10
11
declare(strict_types=1);
12
13
namespace PHPinnacle\Elastics\Traits;
14
15
trait Fuzzy
16
{
17
    use
18
        Boost,
19
        MaxExpansions,
20
        PrefixLength
21
    ;
22
23
    /**
24
     * @var string
25
     */
26
    protected $fuzziness;
27
28
    /**
29
     * @var Boolean
30
     */
31
    protected $transpositions;
32
33
    /**
34
     * @param string $fuzziness
35
     *
36
     * @return self
37
     */
38 5
    public function fuzziness(string $fuzziness): self
39
    {
40 5
        $this->fuzziness = $fuzziness;
41
42 5
        return $this;
43
    }
44
45
    /**
46
     * @param Boolean $transpositions
47
     *
48
     * @return self
49
     */
50 4
    public function transpositions(bool $transpositions): self
51
    {
52 4
        $this->transpositions = $transpositions;
53
54 4
        return $this;
55
    }
56
}
57