FileNotFound   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 12
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
dl 0
loc 12
ccs 0
cts 4
cp 0
rs 10
c 0
b 0
f 0
wmc 2
lcom 0
cbo 1

2 Methods

Rating   Name   Duplication   Size   Complexity  
A withPath() 0 4 1
A staticFile() 0 4 1
1
<?php
2
3
namespace Stitcher\Exception;
4
5
class FileNotFound extends StitcherException
6
{
7
    public static function withPath(string $path, string $source = null): self
8
    {
9
        return new self("File not found in path `{$path}`", $source);
10
    }
11
12
    public static function staticFile(string $path): self
13
    {
14
        return self::withPath($path, 'This file was tried to be copied as a static file. Please see your `staticFiles` configuration.' );
15
    }
16
}
17