Completed
Pull Request — new-version (#111)
by Tom
02:24
created

FullName   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 20
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
dl 0
loc 20
rs 10
c 0
b 0
f 0
wmc 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A getParser() 0 3 1
A isAllowedMultipleTimes() 0 3 1
A getFormatter() 0 3 1
A getNode() 0 3 1
1
<?php
2
3
namespace JeroenDesloovere\VCard\Property;
4
5
use JeroenDesloovere\VCard\Formatter\Property\FullNameFormatter;
6
use JeroenDesloovere\VCard\Formatter\Property\NodeFormatterInterface;
7
use JeroenDesloovere\VCard\Parser\Property\FullNameParser;
8
use JeroenDesloovere\VCard\Parser\Property\NodeParserInterface;
9
10
final class FullName extends SingleStringValue implements PropertyInterface, SimpleNodeInterface
11
{
12
    public function getFormatter(): NodeFormatterInterface
13
    {
14
        return new FullNameFormatter($this);
15
    }
16
17
    public static function getNode(): string
18
    {
19
        return 'FN';
20
    }
21
22
    public static function getParser(): NodeParserInterface
23
    {
24
        return new FullNameParser();
25
    }
26
27
    public function isAllowedMultipleTimes(): bool
28
    {
29
        return false;
30
    }
31
}
32