Completed
Pull Request — development (#809)
by
unknown
04:40
created

CachesEntity::isActiveAndFindableAndSoOn()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 7

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 2
nc 2
nop 0
dl 0
loc 7
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace Oc\Entity;
4
5
use Oc\Repository\AbstractEntity;
6
#use Symfony\Component\Security\Core\User\UserInterface; ??
7
8
#class CachesEntity extends AbstractEntity implements UserInterface // original kopierter Text von UserEntity..
9
class CachesEntity extends AbstractEntity implements CachesInterface
10
{
11
12
    /**
13
     * @var int
14
     */
15
    public $cache_id;
16
17
    /**
18
     * @var datetime
19
     */
20
    public $date_created;
21
22
    /**
23
     * @var datetime
24
     */
25
    public $last_modified;
26
27
    /**
28
     * @var int
29
     */
30
    public $user_id;
31
32
    /**
33
     * @var string
34
     */
35
    public $name;
36
37
    /**
38
     * @var float (DB:double?)
39
     */
40
    public $longitude;
41
42
    /**
43
     * @var float (DB:double?)
44
     */
45
    public $latitude;
46
47
    /**
48
     * @var int
49
     */
50
    public $status;
51
52
    /**
53
     * @var string
54
     */
55
    public $country;
56
57
    /**
58
     * @var int
59
     */
60
    public $difficulty;
61
62
    /**
63
     * @var int
64
     */
65
    public $terrain;
66
67
    /**
68
     * @var int
69
     */
70
    public $size;
71
72
    /**
73
     * @var string (DB:varchar)
74
     */
75
    public $wp_oc;
76
77
    /**
78
     * @var string (DB:varchar)
79
     */
80
    public $wp_gc;
81
82
    /**
83
     * @var string (DB:varchar)
84
     */
85
    public $wp_nc;
86
87
    public function isNew(): bool
88
    {
89
        #Hinweis vom Scrutinizer: "There is one abstract method isNew in this class; you could implement it, or declare this class as abstract."
90
        // TODO: Implement isNew() method.
91
    }
92
93
    /**
94
     *
95
     */
96
    public function isActiveAndFindableAndSoOn(): bool
97
    {
98
        if ($this->status == 1)
99
            return $this->true;
100
        else
101
            return $this->false;
102
    }
103
104
    public function getID(): int
105
    {
106
        return $this->cache_id;
107
    }
108
109
    public function getName(): string
110
    {
111
        return $this->name;
112
    }
113
114
    public function getGCid(): string
115
    {
116
        return $this->wp_gc;
117
    }
118
119
    public function getOCid(): string
120
    {
121
        return $this->wp_oc;
122
    }
123
124
    public function getStatus(): string
125
    {
126
        return $this->status;
127
    }
128
129
/*
130
    public function getRoles(): array
131
    {
132
        return $this->roles;
133
    }
134
135
    public function getPassword(): ?string
136
    {
137
        return $this->password;
138
    }
139
140
    public function getSalt(): string
141
    {
142
        return '';
143
    }
144
145
    public function getUsername(): string
146
    {
147
        return $this->username;
148
    }
149
150
    public function eraseCredentials(): void
151
    {
152
    }
153
*/
154
155
}
156