Passed
Pull Request — master (#81)
by
unknown
05:47
created

UnderscoreNameGenerator::generateName()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
c 0
b 0
f 0
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 1
1
<?php
2
3
namespace Gesdinet\JWTRefreshTokenBundle\NameGenerator;
4
5
use Doctrine\Common\Inflector\Inflector;
6
7
/**
8
 * Class UnderscoreNameGenerator
9
 *
10
 * @package Gesdinet\JWTRefreshTokenBundle\NameGenerator
11
 *
12
 * @see UnderscoreNameGeneratorSpec for unit tests
13
 */
14
class UnderscoreNameGenerator implements NameGeneratorInterface
15
{
16
    /**
17
     * @param string $name
18
     *
19
     * @return string
20
     */
21
    public function generateName($name)
22
    {
23
        return Inflector::tableize($name);
24
    }
25
}
26