StatementResult   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 42
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 5
Bugs 1 Features 0
Metric Value
wmc 3
c 5
b 1
f 0
lcom 0
cbo 0
dl 0
loc 42
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 5 1
A getStatements() 0 4 1
A getMoreUrlPath() 0 4 1
1
<?php
2
3
/*
4
 * This file is part of the xAPI package.
5
 *
6
 * (c) Christian Flothmann <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace Xabbuh\XApi\Model;
13
14
/**
15
 * Result when querying a Learning Record Store (LRS) for a list of
16
 * {@link Statement Statements}.
17
 *
18
 * @author Christian Flothmann <[email protected]>
19
 */
20
final class StatementResult
21
{
22
    /**
23
     * @var Statement[] The collection of Statements
24
     */
25
    private $statements;
26
27
    /**
28
     * @var string
29
     */
30
    private $moreUrlPath;
31
32
    /**
33
     * @param Statement[] $statements The collection of Statements
34
     * @param string      $urlPath    The URL path
35
     */
36
    public function __construct(array $statements, $urlPath = null)
37
    {
38
        $this->statements = $statements;
39
        $this->moreUrlPath = $urlPath;
40
    }
41
42
    /**
43
     * Returns the Statements.
44
     *
45
     * @return Statement[] The Statements
46
     */
47
    public function getStatements()
48
    {
49
        return $this->statements;
50
    }
51
52
    /**
53
     * Returns the absolute path under which the next results can be retrieved.
54
     *
55
     * @return string The URL path
56
     */
57
    public function getMoreUrlPath()
58
    {
59
        return $this->moreUrlPath;
60
    }
61
}
62