FileInfo   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
eloc 14
dl 0
loc 19
ccs 0
cts 7
cp 0
rs 10
c 0
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 8 1
1
<?php
2
3
/*
4
 * This file is part of the Silverback API Components Bundle Project
5
 *
6
 * (c) Daniel West <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
declare(strict_types=1);
13
14
namespace Silverback\ApiComponentsBundle\Entity\Core;
15
16
use Silverback\ApiComponentsBundle\Entity\Utility\IdTrait;
17
18
/**
19
 * Optional entity only mapped if imagine installed.
20
 *
21
 * @author Daniel West <[email protected]>
22
 */
23
class FileInfo
24
{
25
    use IdTrait;
26
27
    public string $path;
28
    public string $mimeType;
29
    public int $fileSize;
30
    public ?int $width;
31
    public ?int $height;
32
    public ?string $filter;
33
34
    public function __construct(string $path, string $mimeType, int $fileSize, ?int $width, ?int $height, ?string $filter = null)
35
    {
36
        $this->path = $path;
37
        $this->mimeType = $mimeType;
38
        $this->width = $width;
39
        $this->height = $height;
40
        $this->fileSize = $fileSize;
41
        $this->filter = $filter;
42
    }
43
}
44