Store   A
last analyzed

Complexity

Total Complexity 15

Size/Duplication

Total Lines 76
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 16
c 1
b 0
f 0
dl 0
loc 76
rs 10
wmc 15

15 Methods

Rating   Name   Duplication   Size   Complexity  
A getStreet() 0 3 1
A getStreetNum() 0 3 1
A setCity() 0 3 1
A setName() 0 3 1
A setStreet() 0 3 1
A getCity() 0 3 1
A setStreetNum() 0 3 1
A setPostcode() 0 3 1
A getLongitude() 0 3 1
A getLatitude() 0 3 1
A setLongitude() 0 3 1
A getPostCode() 0 3 1
A _construct() 0 3 1
A setLatitude() 0 3 1
A getName() 0 3 1
1
<?php
2
/**
3
 * Copyright (c) 2019 Lars Roettig
4
 *
5
 * Permission is hereby granted, free of charge, to any person obtaining a copy
6
 * of this software and associated documentation files (the "Software"), to deal
7
 * in the Software without restriction, including without limitation the rights
8
 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
 * copies of the Software, and to permit persons to whom the Software is
10
 * furnished to do so, subject to the following conditions:
11
 *
12
 * The above copyright notice and this permission notice shall be included in all
13
 * copies or substantial portions of the Software.
14
 *
15
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
 * SOFTWARE.
22
 */
23
declare(strict_types=1);
24
25
namespace LarsRoettig\GraphQLStorePickup\Model;
26
27
use LarsRoettig\GraphQLStorePickup\Api\Data\StoreInterface;
28
use LarsRoettig\GraphQLStorePickup\Model\ResourceModel\Store as StoreResourceModel;
29
use Magento\Framework\Model\AbstractExtensibleModel;
30
31
class Store extends AbstractExtensibleModel implements StoreInterface
32
{
33
34
    protected function _construct()
35
    {
36
        $this->_init(StoreResourceModel::class);
37
    }
38
39
    public function getName(): ?string
40
    {
41
        return $this->getData(self::NAME);
42
    }
43
44
    public function setName(?string $name): void
45
    {
46
        $this->setData(self::NAME, $name);
47
    }
48
49
    public function getStreet(): ?string
50
    {
51
        return $this->getData(self::STREET);
52
    }
53
54
    public function setStreet(?string $street): void
55
    {
56
        $this->setData(self::STREET, $street);
57
    }
58
59
    public function getStreetNum(): ?int
60
    {
61
        return $this->getData(self::STREET_NUM);
62
    }
63
64
    public function setStreetNum(?int $streetNum): void
65
    {
66
        $this->setData(self::STREET_NUM, $streetNum);
67
    }
68
69
    public function getCity(): ?string
70
    {
71
        return $this->getData(self::CITY);
72
    }
73
74
    public function setCity(?string $city): void
75
    {
76
        $this->setData(self::CITY, $city);
77
    }
78
79
    public function getPostCode(): ?int
80
    {
81
        return $this->getData(self::POSTCODE);
82
    }
83
84
    public function setPostcode(?int $postCode): void
85
    {
86
        $this->setData(self::POSTCODE, $postCode);
87
    }
88
89
    public function getLatitude(): ?float
90
    {
91
        return $this->getData(self::LATITUDE);
92
    }
93
94
    public function setLatitude(?float $latitude): void
95
    {
96
        $this->setData(self::LATITUDE, $latitude);
97
    }
98
99
    public function getLongitude(): ?float
100
    {
101
        return $this->getData(self::LONGITUDE);
102
    }
103
104
    public function setLongitude(?float $longitude): void
105
    {
106
        $this->setData(self::LONGITUDE, $longitude);
107
    }
108
}
109