StandardDateFactory   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 8
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
dl 0
loc 8
rs 10
c 0
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A map() 0 3 1
1
<?php
2
3
namespace Popy\Calendar\Parser\ResultMapper;
4
5
use Popy\Calendar\Parser\DateLexerResult;
6
use Popy\Calendar\Parser\ResultMapperInterface;
7
use Popy\Calendar\ValueObject\DateRepresentationInterface;
8
use Popy\Calendar\ValueObject\DateRepresentation\Standard;
9
10
/**
11
 * Builds a standard date representation (to initialize a mapper chain).
12
 */
13
class StandardDateFactory implements ResultMapperInterface
14
{
15
    /**
16
     * @inheritDoc
17
     */
18
    public function map(DateLexerResult $parts, DateRepresentationInterface $date = null)
19
    {
20
        return new Standard();
21
    }
22
}
23