Passed
Branch master (b4f9b9)
by Maxime
03:00
created

RateChecker::getMembersFields()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 19
Code Lines 16

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 16
CRAP Score 1

Importance

Changes 3
Bugs 1 Features 2
Metric Value
c 3
b 1
f 2
dl 0
loc 19
ccs 16
cts 16
cp 1
rs 9.4285
cc 1
eloc 16
nc 1
nop 0
crap 1
1
<?php
2
3
namespace Mhor\MediaInfo\Checker;
4
5
use Mhor\MediaInfo\Attribute\Rate;
6
7
class RateChecker extends AbstractAttributeChecker
8
{
9
    /**
10
     * @param array $value
11
     *
12
     * @return Rate
13
     */
14 3
    public function create($value)
15
    {
16 3
        $rate = new Rate($value[0], $value[1]);
17
18 3
        return $rate;
19
    }
20
21
    /**
22
     * @return array
23
     */
24 3
    public function getMembersFields()
25
    {
26
        return array(
27 3
            'maximum_bit_rate',
28 3
            'channel_s',
29 3
            'bit_rate',
30 3
            'sampling_rate',
31 3
            'bit_depth',
32 3
            'width',
33 3
            'nominal_bit_rate',
34 3
            'frame_rate',
35 3
            'display_aspect_ratio',
36 3
            'frame_rate',
37 3
            'format_settings_reframes',
38 3
            'height',
39 3
            'resolution',
40 3
            'original_display_aspect_ratio',
41 3
        );
42
    }
43
}
44