BaseResource::getDateUtil()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 7
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 3
dl 0
loc 7
rs 10
c 0
b 0
f 0
cc 2
nc 2
nop 0
1
<?php
2
3
namespace Ipag\Classes;
4
5
abstract class BaseResource
6
{
7
    /**
8
     * @var Util\NumberUtil
9
     */
10
    private $numberUtil;
11
12
    /**
13
     * @var Util\DateUtil
14
     */
15
    private $dateUtil;
16
17
    /**
18
     * @return Util\NumberUtil
19
     */
20
    public function getNumberUtil()
21
    {
22
        if (is_null($this->numberUtil)) {
23
            $this->numberUtil = new Util\NumberUtil();
24
        }
25
26
        return $this->numberUtil;
27
    }
28
29
    /**
30
     * @return Util\DateUtil
31
     */
32
    public function getDateUtil()
33
    {
34
        if (is_null($this->dateUtil)) {
35
            $this->dateUtil = new Util\DateUtil();
36
        }
37
38
        return $this->dateUtil;
39
    }
40
}
41