Completed
Push — master ( 4e34cd...643d5b )
by Manel
13:04
created

PersonRepositoryEloquent::model()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
dl 0
loc 4
rs 10
c 1
b 0
f 0
cc 1
eloc 2
nc 1
nop 0
1
<?php
2
3
namespace Scool\EnrollmentMobile\Repositories;
4
5
use Prettus\Repository\Eloquent\BaseRepository;
6
use Prettus\Repository\Criteria\RequestCriteria;
7
use Scool\EnrollmentMobile\Repositories\PersonRepository;
8
use Scool\EnrollmentMobile\Entities\Person;
9
use Scool\EnrollmentMobile\Validators\PersonValidator;
10
11
/**
12
 * Class PersonRepositoryEloquent
13
 * @package namespace Scool\EnrollmentMobile\Repositories;
14
 */
15
class PersonRepositoryEloquent extends BaseRepository implements PersonRepository
16
{
17
    /**
18
     * Specify Model class name
19
     *
20
     * @return string
21
     */
22
    public function model()
23
    {
24
        return Person::class;
25
    }
26
27
    /**
28
    * Specify Validator class name
29
    *
30
    * @return mixed
31
    */
32
    public function validator()
33
    {
34
35
        return PersonValidator::class;
36
    }
37
38
39
    /**
40
     * Boot up the repository, pushing criteria
41
     */
42
    public function boot()
43
    {
44
        $this->pushCriteria(app(RequestCriteria::class));
45
    }
46
}
47