Passed
Push — master ( b0e1d7...34bc8c )
by
unknown
02:32
created

Hook::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
c 0
b 0
f 0
dl 0
loc 5
rs 9.4285
cc 1
eloc 3
nc 1
nop 0
1
<?php
2
/**
3
 * Created by Graham Owens ([email protected])
4
 * Company: PartFire Ltd (www.partfire.co.uk)
5
 * Console: Discovery
6
 *
7
 * User:    gra
8
 * Date:    20/01/17
9
 * Time:    09:13
10
 * Project: fruitful-property-investments
11
 * File:    Hook.php
12
 *
13
 **/
14
15
namespace PartFire\MangoPayBundle\Entity;
16
17
use Doctrine\ORM\Mapping as ORM;
18
use Doctrine\ORM\Mapping\MappedSuperclass;
19
use Gedmo\Mapping\Annotation as Gedmo;
20
use Doctrine\Common\Collections\ArrayCollection;
21
use JMS\Serializer\Annotation\ExclusionPolicy;
22
use JMS\Serializer\Annotation\Expose;
23
use PartFire\CommonBundle\Entity\CommonBaseEntity;
24
use PartFire\MangoPayBundle\MangoPayConstants;
25
26
27
/**
28
 * @ORM\Entity
29
 * @ORM\Table(name="partfire_mango_hook", indexes={
30
 *  @ORM\Index(name="index_enabled", columns={"enabled", "deleted", "status"}) })
31
 * @ORM\Entity(repositoryClass="PartFire\MangoPayBundle\Entity\Repository\HookRepository")
32
 * @ExclusionPolicy("all")
33
 */
34
35
class Hook extends CommonBaseEntity
36
{
37
    /**
38
     * @ORM\Column(name="hookId",type="string", length=255, unique=true, nullable=false);
39
     *
40
     */
41
42
    private $hookId;
43
44
    /**
45
     * @ORM\Column(name="hook_creation_date",type="string", length=255, nullable=false);
46
     *
47
     */
48
49
    private $hookCreationDate;
50
51
    /**
52
     * @ORM\Column(name="hook_tag",type="string", length=255, nullable=false);
53
     *
54
     */
55
56
    private $hookTag;
57
58
    /**
59
     * @ORM\Column(name="hook_url",type="string", length=255, nullable=false);
60
     *
61
     */
62
63
    private $hookUrl;
64
65
    /**
66
     * @ORM\Column(name="hook_status",type="string", length=255, nullable=false);
67
     *
68
     */
69
70
    private $hookStatus;
71
72
    /**
73
     * @ORM\Column(name="hook_validity",type="string", length=255, nullable=false);
74
     *
75
     */
76
77
    private $hookValidity;
78
79
    /**
80
     * @ORM\Column(name="hook_event_type",type="string", length=255, nullable=false);
81
     *
82
     */
83
84
    private $hookEventType;
85
86
    /**
87
     * @ORM\Column(name="raw_hook_data",type="string", length=500, nullable=false);
88
     *
89
     */
90
91
    private $rawHookData;
92
93
    /**
94
     * @var string
95
     *
96
     * @ORM\Column(name="status", type="string", length=200, nullable=false)
97
     */
98
    protected $status;
99
100
    public function __construct()
101
    {
102
        parent::__construct();
103
        $this->status = MangoPayConstants::HOOK_NEW;
104
    }
105
106
    /**
107
     * @return mixed
108
     */
109
    public function getHookId()
110
    {
111
        return $this->hookId;
112
    }
113
114
    /**
115
     * @param mixed $hookId
116
     */
117
    public function setHookId($hookId)
118
    {
119
        $this->hookId = $hookId;
120
    }
121
122
    /**
123
     * @return mixed
124
     */
125
    public function getHookCreationDate()
126
    {
127
        return $this->hookCreationDate;
128
    }
129
130
    /**
131
     * @param mixed $hookCreationDate
132
     */
133
    public function setHookCreationDate($hookCreationDate)
134
    {
135
        $this->hookCreationDate = $hookCreationDate;
136
    }
137
138
    /**
139
     * @return mixed
140
     */
141
    public function getHookTag()
142
    {
143
        return $this->hookTag;
144
    }
145
146
    /**
147
     * @param mixed $hookTag
148
     */
149
    public function setHookTag($hookTag)
150
    {
151
        $this->hookTag = $hookTag;
152
    }
153
154
    /**
155
     * @return mixed
156
     */
157
    public function getHookUrl()
158
    {
159
        return $this->hookUrl;
160
    }
161
162
    /**
163
     * @param mixed $hookUrl
164
     */
165
    public function setHookUrl($hookUrl)
166
    {
167
        $this->hookUrl = $hookUrl;
168
    }
169
170
    /**
171
     * @return mixed
172
     */
173
    public function getHookStatus()
174
    {
175
        return $this->hookStatus;
176
    }
177
178
    /**
179
     * @param mixed $hookStatus
180
     */
181
    public function setHookStatus($hookStatus)
182
    {
183
        $this->hookStatus = $hookStatus;
184
    }
185
186
    /**
187
     * @return mixed
188
     */
189
    public function getHookValidity()
190
    {
191
        return $this->hookValidity;
192
    }
193
194
    /**
195
     * @param mixed $hookValidity
196
     */
197
    public function setHookValidity($hookValidity)
198
    {
199
        $this->hookValidity = $hookValidity;
200
    }
201
202
    /**
203
     * @return mixed
204
     */
205
    public function getHookEventType()
206
    {
207
        return $this->hookEventType;
208
    }
209
210
    /**
211
     * @param mixed $hookEventType
212
     */
213
    public function setHookEventType($hookEventType)
214
    {
215
        $this->hookEventType = $hookEventType;
216
    }
217
218
    /**
219
     * @return string
220
     */
221
    public function getStatus(): string
222
    {
223
        return $this->status;
224
    }
225
226
    /**
227
     * @param string $status
228
     */
229
    public function setStatus(string $status)
230
    {
231
        $this->status = $status;
232
    }
233
234
    /**
235
     * @return mixed
236
     */
237
    public function getRawHookData()
238
    {
239
        return $this->rawHookData;
240
    }
241
242
    /**
243
     * @param mixed $rawHookData
244
     */
245
    public function setRawHookData($rawHookData)
246
    {
247
        $this->rawHookData = $rawHookData;
248
    }
249
250
251
}