Passed
Pull Request — 1.11.x (#4501)
by Angel Fernando Quiroz
09:49
created

PortfolioComment   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
eloc 7
c 1
b 0
f 0
dl 0
loc 14
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
1
<?php
2
3
/* For licensing terms, see /license.txt */
4
5
namespace Chamilo\PluginBundle\XApi\ToolExperience\Statement;
6
7
use Chamilo\CoreBundle\Entity\Portfolio as PortfolioEntity;
8
use Chamilo\CoreBundle\Entity\PortfolioComment as PortfolioCommentEntity;
9
10
abstract class PortfolioComment extends BaseStatement
11
{
12
    /** @var PortfolioCommentEntity */
13
    protected $comment;
14
    /** @var PortfolioCommentEntity|null */
15
    protected $parentComment;
16
    /** @var PortfolioEntity */
17
    protected $item;
18
19
    public function __construct(PortfolioCommentEntity $comment)
20
    {
21
        $this->comment = $comment;
22
        $this->item = $this->comment->getItem();
23
        $this->parentComment = $this->comment->getParent();
24
    }
25
}
26