Completed
Push — master ( 116c2b...dd19e9 )
by Ryan
14:29 queued 06:49
created

ViewTemplate::__toString()   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
c 1
b 0
f 0
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 0
1
<?php namespace Anomaly\Streams\Platform\View;
2
3
use Illuminate\Support\Collection;
4
5
/**
6
 * Class ViewTemplate
7
 *
8
 * @link          http://anomaly.is/streams-platform
9
 * @author        AnomalyLabs, Inc. <[email protected]>
10
 * @author        Ryan Thompson <[email protected]>
11
 * @package       Anomaly\Streams\Platform\View
12
 */
13
class ViewTemplate extends Collection
14
{
15
16
    /**
17
     * The loaded flag.
18
     *
19
     * @var bool
20
     */
21
    protected $loaded = false;
22
23
    /**
24
     * Set a value.
25
     *
26
     * @param $key
27
     * @param $value
28
     * @return $this
29
     */
30
    public function set($key, $value)
31
    {
32
        $this->put($key, $value);
33
34
        return $this;
35
    }
36
37
    /**
38
     * Get the loaded flag.
39
     *
40
     * @return bool
41
     */
42
    public function isLoaded()
43
    {
44
        return $this->loaded;
45
    }
46
47
    /**
48
     * Set the loaded flag.
49
     *
50
     * @param $loaded
51
     * @return $this
52
     */
53
    public function setLoaded($loaded)
54
    {
55
        $this->loaded = $loaded;
56
57
        return $this;
58
    }
59
60
    /**
61
     * Override the string output.
62
     *
63
     * @return string
64
     */
65
    public function __toString()
66
    {
67
        return '';
68
    }
69
}
70