UserRoleRepositorySql   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 5
c 1
b 0
f 0
dl 0
loc 13
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A all() 0 6 1
A add() 0 2 1
1
<?php
2
3
4
namespace App\Src\UseCases\Infra\Sql;
5
6
7
use App\Src\UseCases\Domain\Ports\UserRoleRepository;
8
use App\Src\UseCases\Domain\Users\Dto\Role;
9
use App\Src\UseCases\Domain\Users\Dto\WikiUserRole;
10
use Illuminate\Support\Collection;
11
12
class UserRoleRepositorySql implements UserRoleRepository
13
{
14
    public function add(Role $role)
15
    {
16
17
    }
18
19
    public function all():Collection
20
    {
21
        return collect([
22
            new WikiUserRole('farmer'),
23
            new WikiUserRole('student'),
24
            new WikiUserRole('advisor'),
25
        ]);
26
    }
27
}
28