Passed
Push — master ( 1f7f34...948e88 )
by Thomas
04:12 queued 02:03
created

RouteFile   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 26
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 3
lcom 1
cbo 1
dl 0
loc 26
ccs 0
cts 12
cp 0
rs 10
c 0
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A getName() 0 4 1
A getFileName() 0 4 1
A getPath() 0 4 1
1
<?php
2
3
namespace Webfactor\Laravel\Generators\Schemas\Naming;
4
5
use Carbon\Carbon;
6
use Webfactor\Laravel\Generators\Contracts\NamingAbstract;
7
8
class RouteFile extends NamingAbstract
9
{
10
    /**
11
     * @return string
12
     */
13
    public function getName(): string
14
    {
15
        return snake_case($this->entity);
16
    }
17
18
    /**
19
     * @return string
20
     */
21
    public function getFileName(): string
22
    {
23
        return 'custom.php';
24
    }
25
26
    /**
27
     * @return string
28
     */
29
    public function getPath(): string
30
    {
31
        return base_path('routes/backpack');
32
    }
33
}
34