Completed
Push — master ( 39a0bd...0a53a0 )
by Fabian
02:26
created

OrderBookModel   A

Complexity

Total Complexity 4

Size/Duplication

Total Lines 50
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 0
Metric Value
dl 0
loc 50
ccs 11
cts 11
cp 1
rs 10
c 0
b 0
f 0
wmc 4

4 Methods

Rating   Name   Duplication   Size   Complexity  
A getTimestamp() 0 3 1
A getVolume() 0 3 1
A getPrice() 0 3 1
A __construct() 0 5 1
1
<?php
2
/**
3
 * @author Fabian Hanisch
4
 * @since 18.07.2017 20:32
5
 * @version 1.0
6
 */
7
8
namespace HanischIt\KrakenApi\Call\OrderBook\Model;
9
10
/**
11
 * Class OrderBookModel
12
 * @package HanischIt\KrakenApi\Call\OrderBook
13
 */
14
class OrderBookModel
15
{
16
    /**
17
     * @var float
18
     */
19
    private $price;
20
    /**
21
     * @var float
22
     */
23
    private $volume;
24
    /**
25
     * @var string
26
     */
27
    private $timestamp;
28
29
    /**
30
     * OrderBookModel constructor.
31
     * @param float $price
32
     * @param float $volume
33
     * @param string $timestamp
34
     */
35 1
    public function __construct($price, $volume, $timestamp)
36
    {
37 1
        $this->price = $price;
38 1
        $this->volume = $volume;
39 1
        $this->timestamp = $timestamp;
40 1
    }
41
42
    /**
43
     * @return float
44
     */
45 1
    public function getPrice()
46
    {
47 1
        return $this->price;
48
    }
49
50
    /**
51
     * @return float
52
     */
53 1
    public function getVolume()
54
    {
55 1
        return $this->volume;
56
    }
57
58
    /**
59
     * @return string
60
     */
61 1
    public function getTimestamp()
62
    {
63 1
        return $this->timestamp;
64
    }
65
}
66