Chan   A
last analyzed

Complexity

Total Complexity 6

Size/Duplication

Total Lines 75
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
eloc 13
dl 0
loc 75
rs 10
c 0
b 0
f 0
wmc 6

6 Methods

Rating   Name   Duplication   Size   Complexity  
A setTime() 0 5 1
A getNote() 0 3 1
A setDate() 0 5 1
A getTime() 0 3 1
A addNote() 0 5 1
A getDate() 0 3 1
1
<?php
2
/**
3
 * php-gedcom.
4
 *
5
 * php-gedcom is a library for parsing, manipulating, importing and exporting
6
 * GEDCOM 5.5 files in PHP 5.3+.
7
 *
8
 * @author          Kristopher Wilson <[email protected]>
9
 * @copyright       Copyright (c) 2010-2013, Kristopher Wilson
10
 * @license         MIT
11
 *
12
 * @link            http://github.com/mrkrstphr/php-gedcom
13
 */
14
15
namespace PhpGedcom\Record;
16
17
use PhpGedcom\Record;
18
19
/**
20
 * Class Chan.
21
 */
22
class Chan extends Record
23
{
24
    /**
25
     * @var string
26
     */
27
    protected $date;
28
29
    /**
30
     * @var string
31
     */
32
    protected $time;
33
34
    /**
35
     * @var array
36
     */
37
    protected $note = [];
38
39
    /**
40
     * @param string $date
41
     *
42
     * @return Chan
43
     */
44
    public function setDate($date = '')
45
    {
46
        $this->date = $date;
47
48
        return $this;
49
    }
50
51
    /**
52
     * @return string
53
     */
54
    public function getDate()
55
    {
56
        return $this->date;
57
    }
58
59
    /**
60
     * @param Record\NoteRef $note
61
     *
62
     * @return Chan
63
     */
64
    public function addNote($note = [])
65
    {
66
        $this->note[] = $note;
67
68
        return $this;
69
    }
70
71
    /**
72
     * @return array
73
     */
74
    public function getNote()
75
    {
76
        return $this->note;
77
    }
78
79
    /**
80
     * @param string $time
81
     *
82
     * @return Chan
83
     */
84
    public function setTime($time = '')
85
    {
86
        $this->time = $time;
87
88
        return $this;
89
    }
90
91
    /**
92
     * @return string
93
     */
94
    public function getTime()
95
    {
96
        return $this->time;
97
    }
98
}
99