Completed
Push — master ( 6ea9b4...222850 )
by Andreas
04:32
created

WebApplicationTypeMap::getMap()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 10
Code Lines 7

Duplication

Lines 10
Ratio 100 %

Code Coverage

Tests 7
CRAP Score 1

Importance

Changes 0
Metric Value
dl 10
loc 10
ccs 7
cts 7
cp 1
rs 9.4285
c 0
b 0
f 0
cc 1
eloc 7
nc 1
nop 0
crap 1
1
<?php
2
/**
3
 * WebApplicationTypeMap.
4
 *
5
 * @copyright 2018 Institute of Legal Medicine, Medical University of Innsbruck
6
 * @author Andreas Erhard <[email protected]>
7
 * @license LGPL-3.0-only
8
 * @link http://www.gerichtsmedizin.at/
9
 *
10
 * @package fileinfo
11
 */
12
namespace Gmi\Toolkit\Fileinfo\Type;
13
14
/**
15
 * Type mapping provider for (client-side) web application filetypes.
16
 */
17 View Code Duplication
class WebApplicationTypeMap implements TypeMapInterface
1 ignored issue
show
Duplication introduced by
This class seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
18
{
19
    /**
20
     * {@inheritdoc}
21
     */
22 9
    public function getMap()
23
    {
24
        return [
25 9
            new Type(['css'], 'text/css'),
26 9
            new Type(['html', 'htm'], 'text/html'),
27 9
            new Type(['js'], 'application/javascript'),
28 9
            new Type(['swf'], 'application/x-shockwave-flash'),
29 9
            new Type(['xhtml'], 'application/xhtml+xml'),
30 9
        ];
31
    }
32
}
33