1
|
|
|
<?php |
2
|
|
|
/** |
3
|
|
|
* @author @jayS-de <[email protected]> |
4
|
|
|
*/ |
5
|
|
|
|
6
|
|
|
namespace Commercetools\Core\Model\Subscription; |
7
|
|
|
|
8
|
|
|
use Commercetools\Core\Model\Common\Reference; |
9
|
|
|
use Commercetools\Core\Model\Common\DateTimeDecorator; |
10
|
|
|
|
11
|
|
|
/** |
12
|
|
|
* @package Commercetools\Core\Model\Subscription |
13
|
|
|
* @method string getProjectKey() |
14
|
|
|
* @method MessageDelivery setProjectKey(string $projectKey = null) |
15
|
|
|
* @method string getNotificationType() |
16
|
|
|
* @method MessageDelivery setNotificationType(string $notificationType = null) |
17
|
|
|
* @method Reference getResource() |
18
|
|
|
* @method MessageDelivery setResource(Reference $resource = null) |
19
|
|
|
* @method string getId() |
20
|
|
|
* @method MessageDelivery setId(string $id = null) |
21
|
|
|
* @method int getVersion() |
22
|
|
|
* @method MessageDelivery setVersion(int $version = null) |
23
|
|
|
* @method int getSequenceNumber() |
24
|
|
|
* @method MessageDelivery setSequenceNumber(int $sequenceNumber = null) |
25
|
|
|
* @method int getResourceVersion() |
26
|
|
|
* @method MessageDelivery setResourceVersion(int $resourceVersion = null) |
27
|
|
|
* @method DateTimeDecorator getCreatedAt() |
28
|
|
|
* @method MessageDelivery setCreatedAt(\DateTime $createdAt = null) |
29
|
|
|
* @method DateTimeDecorator getLastModifiedAt() |
30
|
|
|
* @method MessageDelivery setLastModifiedAt(\DateTime $lastModifiedAt = null) |
31
|
|
|
*/ |
32
|
|
|
class MessageDelivery extends Delivery |
33
|
|
|
{ |
34
|
|
|
public function fieldDefinitions() |
35
|
|
|
{ |
36
|
|
|
$definition = parent::fieldDefinitions(); |
37
|
|
|
$definition = array_merge( |
38
|
|
|
$definition, |
39
|
|
|
[ |
40
|
|
|
'id' => [static::TYPE => 'string'], |
41
|
|
|
'version' => [static::TYPE => 'int'], |
42
|
|
|
'sequenceNumber' => [static::TYPE => 'int'], |
43
|
|
|
'resourceVersion' => [static::TYPE => 'int'], |
44
|
|
|
'createdAt' => [ |
45
|
|
|
static::TYPE => '\DateTime', |
46
|
|
|
static::DECORATOR => '\Commercetools\Core\Model\Common\DateTimeDecorator' |
47
|
|
|
], |
48
|
|
|
'lastModifiedAt' => [ |
49
|
|
|
static::TYPE => '\DateTime', |
50
|
|
|
static::DECORATOR => '\Commercetools\Core\Model\Common\DateTimeDecorator' |
51
|
|
|
], |
52
|
|
|
] |
53
|
|
|
); |
54
|
|
|
return $definition; |
55
|
|
|
} |
56
|
|
|
} |
57
|
|
|
|