EventStreamDoesNotExistException   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 0
dl 0
loc 17
ccs 3
cts 3
cp 1
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A fromStreamId() 0 8 1
1
<?php
2
3
namespace DDDominio\EventSourcing\EventStore;
4
5
class EventStreamDoesNotExistException extends \Exception
6
{
7
    /**
8
     * @param $streamId
9
     * @param int $code
10
     * @param \Exception|null $previous
11
     * @return EventStreamDoesNotExistException
12
     */
13 6
    public static function fromStreamId($streamId, $code = 0, \Exception $previous = null)
14
    {
15 6
        return new self(
16 6
            sprintf('The stream of id %s does not exist', $streamId),
17
            $code,
18
            $previous
19
        );
20
    }
21
}
22