commercetools-sdk-php-v2
The commercetools platform, import-api and PHP sdks generated from our api reference.
lib
commercetools-api
src
Models
OrderEdit
OrderEditApplyModel.php
1
<?php
2
3
declare(strict_types=1);
9
namespace
Commercetools\Api\Models\OrderEdit
;
10
11
use
Commercetools\Base\DateTimeImmutableCollection
;
12
use
Commercetools\Base\JsonObject
;
13
use
Commercetools\Base\JsonObjectModel
;
14
use
Commercetools\Base\MapperFactory
;
15
use stdClass;
16
20
final
class
OrderEditApplyModel
extends
JsonObjectModel
implements
OrderEditApply
21
{
26
protected
$editVersion
;
27
32
protected
$resourceVersion
;
33
34
38
public
function
__construct
(
39
?
int
$editVersion
=
null
,
40
?
int
$resourceVersion
=
null
41
) {
42
$this->editVersion =
$editVersion
;
43
$this->resourceVersion =
$resourceVersion
;
44
}
45
52
public
function
getEditVersion
()
53
{
54
if
(is_null($this->editVersion)) {
56
$data = $this->
raw
(self::FIELD_EDIT_VERSION);
57
if
(is_null($data)) {
58
return
null
;
59
}
60
$this->editVersion = (int) $data;
61
}
62
63
return
$this->editVersion
;
64
}
65
72
public
function
getResourceVersion
()
73
{
74
if
(is_null($this->resourceVersion)) {
76
$data = $this->
raw
(self::FIELD_RESOURCE_VERSION);
77
if
(is_null($data)) {
78
return
null
;
79
}
80
$this->resourceVersion = (int) $data;
81
}
82
83
return
$this->resourceVersion
;
84
}
85
86
90
public
function
setEditVersion
(?
int
$editVersion
): void
91
{
92
$this->editVersion =
$editVersion
;
93
}
94
98
public
function
setResourceVersion
(?
int
$resourceVersion
): void
99
{
100
$this->resourceVersion =
$resourceVersion
;
101
}
102
}
Commercetools\Api\Models\OrderEdit\OrderEditApplyModel
Definition:
OrderEditApplyModel.php:21
Commercetools\Api\Models\OrderEdit\OrderEditApplyModel\setEditVersion
setEditVersion(?int $editVersion)
Definition:
OrderEditApplyModel.php:90
Commercetools\Api\Models\OrderEdit\OrderEditApplyModel\__construct
__construct(?int $editVersion=null, ?int $resourceVersion=null)
Definition:
OrderEditApplyModel.php:38
Commercetools\Api\Models\OrderEdit\OrderEditApplyModel\getEditVersion
getEditVersion()
Definition:
OrderEditApplyModel.php:52
Commercetools\Api\Models\OrderEdit\OrderEditApplyModel\$resourceVersion
$resourceVersion
Definition:
OrderEditApplyModel.php:32
Commercetools\Api\Models\OrderEdit\OrderEditApplyModel\setResourceVersion
setResourceVersion(?int $resourceVersion)
Definition:
OrderEditApplyModel.php:98
Commercetools\Api\Models\OrderEdit\OrderEditApplyModel\$editVersion
$editVersion
Definition:
OrderEditApplyModel.php:26
Commercetools\Api\Models\OrderEdit\OrderEditApplyModel\getResourceVersion
getResourceVersion()
Definition:
OrderEditApplyModel.php:72
Commercetools\Base\BaseJsonObject\raw
raw(string $field)
Definition:
BaseJsonObject.php:57
Commercetools\Base\DateTimeImmutableCollection
Definition:
DateTimeImmutableCollection.php:21
Commercetools\Base\JsonObjectModel
Definition:
JsonObjectModel.php:15
Commercetools\Base\MapperFactory
Definition:
MapperFactory.php:16
Commercetools\Api\Models\OrderEdit\OrderEditApply
Definition:
OrderEditApply.php:15
Commercetools\Base\JsonObject
Definition:
JsonObject.php:15
Commercetools\Api\Models\OrderEdit
Definition:
OrderEdit.php:9
Generated by
1.9.1