BaseManipulator   A
last analyzed

Complexity

Total Complexity 4

Size/Duplication

Total Lines 32
Duplicated Lines 0 %

Test Coverage

Coverage 57.14%

Importance

Changes 1
Bugs 0 Features 1
Metric Value
eloc 4
dl 0
loc 32
ccs 4
cts 7
cp 0.5714
rs 10
c 1
b 0
f 1
wmc 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A supportedExtensions() 0 3 1
A supportedMimetypes() 0 3 1
A performConversion() 0 2 1
A requirementsAreInstalled() 0 3 1
1
<?php
2
3
namespace ByTIC\MediaLibrary\Media\Manipulators;
4
5
use ByTIC\MediaLibrary\Conversions\Conversion;
6
use ByTIC\MediaLibrary\Media\Media;
7
use Nip\Collection;
8
9
/**
10
 * Class BaseManipulator.
11
 */
12
class BaseManipulator extends AbstractManipulator
13
{
14
    /**
15
     * @return bool
16
     */
17 1
    public function requirementsAreInstalled(): bool
18
    {
19 1
        return true;
20
    }
21
22
    /**
23
     * @return Collection
24
     */
25 1
    public function supportedExtensions(): Collection
26
    {
27 1
        return new Collection([]);
0 ignored issues
show
Deprecated Code introduced by
The class Nip\Collection has been deprecated: Use new Collection class from Nip/Collection repo ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-deprecated  annotation

27
        return /** @scrutinizer ignore-deprecated */ new Collection([]);
Loading history...
28
    }
29
30
    /**
31
     * @return Collection
32
     */
33
    public function supportedMimetypes(): Collection
34
    {
35
        return new Collection([]);
0 ignored issues
show
Deprecated Code introduced by
The class Nip\Collection has been deprecated: Use new Collection class from Nip/Collection repo ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-deprecated  annotation

35
        return /** @scrutinizer ignore-deprecated */ new Collection([]);
Loading history...
36
    }
37
38
    /**
39
     * @param Media      $media
40
     * @param Conversion $conversion
41
     */
42
    public function performConversion(Media $media, Conversion $conversion)
43
    {
44
    }
45
}
46