Passed
Push — master ( cb50ee...221dc3 )
by Julito
07:56
created

CThematicPlanRepository   A

Complexity

Total Complexity 6

Size/Duplication

Total Lines 40
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 12
dl 0
loc 40
rs 10
c 1
b 0
f 0
wmc 6

6 Methods

Rating   Name   Duplication   Size   Complexity  
A setResourceNodeRepository() 0 5 1
A __construct() 0 3 1
A setAuthorizationChecker() 0 5 1
A setSlugify() 0 5 1
A setToolChain() 0 5 1
A setRouter() 0 5 1
1
<?php
2
3
/* For licensing terms, see /license.txt */
4
5
namespace Chamilo\CourseBundle\Repository;
6
7
use Chamilo\CoreBundle\Entity\Course;
8
use Chamilo\CoreBundle\Entity\ResourceNode;
9
use Chamilo\CoreBundle\Entity\Session;
10
use Chamilo\CoreBundle\Entity\User;
11
use Chamilo\CoreBundle\Repository\ResourceNodeRepository;
12
use Chamilo\CoreBundle\ToolChain;
13
use Chamilo\CourseBundle\Entity\CGroup;
14
use Chamilo\CourseBundle\Entity\CThematicPlan;
15
use Cocur\Slugify\SlugifyInterface;
16
use Doctrine\Bundle\DoctrineBundle\Repository\ServiceEntityRepository;
17
use Doctrine\ORM\QueryBuilder;
18
use Doctrine\Persistence\ManagerRegistry;
19
use Symfony\Component\Routing\RouterInterface;
20
use Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface;
21
22
final class CThematicPlanRepository extends ServiceEntityRepository
23
{
24
    public function __construct(ManagerRegistry $registry)
25
    {
26
        parent::__construct($registry, CThematicPlan::class);
27
    }
28
29
    public function setAuthorizationChecker(AuthorizationCheckerInterface $authorizationChecker): self
30
    {
31
        $this->authorizationChecker = $authorizationChecker;
32
33
        return $this;
34
    }
35
36
    public function setRouter(RouterInterface $router): self
37
    {
38
        $this->router = $router;
39
40
        return $this;
41
    }
42
43
    public function setSlugify(SlugifyInterface $slugify): self
44
    {
45
        $this->slugify = $slugify;
46
47
        return $this;
48
    }
49
50
    public function setToolChain(ToolChain $toolChain): self
51
    {
52
        $this->toolChain = $toolChain;
53
54
        return $this;
55
    }
56
57
    public function setResourceNodeRepository(ResourceNodeRepository $resourceNodeRepository): self
58
    {
59
        $this->resourceNodeRepository = $resourceNodeRepository;
60
61
        return $this;
62
    }
63
64
    /*public function getResources(User $user, ResourceNode $parentNode, Course $course = null, Session $session = null, CGroup $group = null): QueryBuilder
65
    {
66
        return $this->getResourcesByCourse($course, $session, $group, $parentNode);
67
    }*/
68
}
69