ExcelBuilder   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 2

Importance

Changes 0
Metric Value
wmc 2
lcom 1
cbo 2
dl 0
loc 19
rs 10
c 0
b 0
f 0

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getWorksheetName() 0 4 1
A setDefaultOptions() 0 5 1
1
<?php
2
3
namespace Pim\Bundle\ExcelConnectorBundle\Excel\Builder;
4
5
use Symfony\Component\OptionsResolver\OptionsResolver;
6
7
/**
8
 * Excel builder for single tabbed files
9
 *
10
 * @author    Antoine Guigan <[email protected]>
11
 * @copyright 2013 Akeneo SAS (http://www.akeneo.com)
12
 * @license   http://opensource.org/licenses/osl-3.0.php  Open Software License (OSL 3.0)
13
 */
14
class ExcelBuilder extends AbstractExcelBuilder
15
{
16
    /**
17
     * {@inheritdoc}
18
     */
19
    protected function getWorksheetName(array $data)
20
    {
21
        return $this->options['worksheet_name'];
22
    }
23
24
    /**
25
     * {@inheritdoc}
26
     */
27
    protected function setDefaultOptions(OptionsResolver $resolver)
28
    {
29
        parent::setDefaultOptions($resolver);
30
        $resolver->setDefaults(['worksheet_name' => 'EXPORT']);
31
    }
32
}
33