Completed
Push — master ( 2319eb...3c4d84 )
by Vladimir
02:22
created

TwigExtension::getFunctions()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
dl 0
loc 7
rs 9.4285
c 0
b 0
f 0
ccs 0
cts 3
cp 0
cc 1
eloc 4
nc 1
nop 0
crap 2
1
<?php
2
3
/**
4
 * @copyright 2017 Vladimir Jimenez
5
 * @license   https://github.com/allejo/stakx/blob/master/LICENSE.md MIT
6
 */
7
8
namespace allejo\stakx\Twig;
9
10
class TwigExtension extends \Twig_Extension
11
{
12
    public function getFilters()
13
    {
14
        return array(
15
            GroupByFilter::get(),
16
            OrderFilter::get(),
17
            WhereFilter::get(),
18
            SelectFilter::get(),
19
            ZipFilter::get(),
20
            Md5Filter::get(),
21
            Sha1Filter::get(),
22
            TableOfContentsFilter::get(),
23
        );
24
    }
25
26
    public function getFunctions()
27
    {
28
        return array(
29
            BaseUrlFunction::get(),
30
            FileFunction::get(),
31
        );
32
    }
33
34
    /**
35
     * Returns the name of the extension.
36
     *
37
     * @return string The extension name
38
     */
39 18
    public function getName()
40
    {
41 18
        return 'stakx_core_extension';
42
    }
43
}
44