LexerDFASerializer   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 10
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 3
c 1
b 0
f 0
dl 0
loc 10
ccs 0
cts 5
cp 0
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 3 1
A getEdgeLabel() 0 3 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace Antlr\Antlr4\Runtime\Dfa;
6
7
use Antlr\Antlr4\Runtime\Utils\StringUtils;
8
use Antlr\Antlr4\Runtime\VocabularyImpl;
9
10
final class LexerDFASerializer extends DFASerializer
11
{
12
    public function __construct(DFA $dfa)
13
    {
14
        parent::__construct($dfa, new VocabularyImpl());
15
    }
16
17
    protected function getEdgeLabel(int $i) : string
18
    {
19
        return \sprintf('\'%s\'', StringUtils::char($i));
20
    }
21
}
22