commercetools-sdk-php-v2
The commercetools platform, import-api and PHP sdks generated from our api reference.
Loading...
Searching...
No Matches
lib
commercetools-api
src
Models
Message
UserProvidedIdentifiersModel.php
1
<?php
2
3
declare(strict_types=1);
9
namespace
Commercetools\Api\Models\Message
;
10
11
use
Commercetools\Api\Models\Common\LocalizedString
;
12
use
Commercetools\Api\Models\Common\LocalizedStringModel
;
13
use
Commercetools\Base\DateTimeImmutableCollection
;
14
use
Commercetools\Base\JsonObject
;
15
use
Commercetools\Base\JsonObjectModel
;
16
use
Commercetools\Base\MapperFactory
;
17
use stdClass;
18
22
final
class
UserProvidedIdentifiersModel
extends
JsonObjectModel
implements
UserProvidedIdentifiers
23
{
28
protected
$key
;
29
34
protected
$externalId
;
35
40
protected
$orderNumber
;
41
46
protected
$customerNumber
;
47
52
protected
$sku
;
53
58
protected
$slug
;
59
64
protected
$containerAndKey
;
65
66
70
public
function
__construct
(
71
?
string
$key
=
null
,
72
?
string
$externalId
=
null
,
73
?
string
$orderNumber
=
null
,
74
?
string
$customerNumber
=
null
,
75
?
string
$sku
=
null
,
76
?
LocalizedString
$slug
=
null
,
77
?
ContainerAndKey
$containerAndKey
=
null
78
) {
79
$this->key =
$key
;
80
$this->externalId =
$externalId
;
81
$this->orderNumber =
$orderNumber
;
82
$this->customerNumber =
$customerNumber
;
83
$this->sku =
$sku
;
84
$this->slug =
$slug
;
85
$this->containerAndKey =
$containerAndKey
;
86
}
87
94
public
function
getKey
()
95
{
96
if
(is_null($this->key)) {
98
$data = $this->
raw
(self::FIELD_KEY);
99
if
(is_null($data)) {
100
return
null
;
101
}
102
$this->key = (string) $data;
103
}
104
105
return
$this->key
;
106
}
107
114
public
function
getExternalId
()
115
{
116
if
(is_null($this->externalId)) {
118
$data = $this->
raw
(self::FIELD_EXTERNAL_ID);
119
if
(is_null($data)) {
120
return
null
;
121
}
122
$this->externalId = (string) $data;
123
}
124
125
return
$this->externalId
;
126
}
127
134
public
function
getOrderNumber
()
135
{
136
if
(is_null($this->orderNumber)) {
138
$data = $this->
raw
(self::FIELD_ORDER_NUMBER);
139
if
(is_null($data)) {
140
return
null
;
141
}
142
$this->orderNumber = (string) $data;
143
}
144
145
return
$this->orderNumber
;
146
}
147
154
public
function
getCustomerNumber
()
155
{
156
if
(is_null($this->customerNumber)) {
158
$data = $this->
raw
(self::FIELD_CUSTOMER_NUMBER);
159
if
(is_null($data)) {
160
return
null
;
161
}
162
$this->customerNumber = (string) $data;
163
}
164
165
return
$this->customerNumber
;
166
}
167
174
public
function
getSku
()
175
{
176
if
(is_null($this->sku)) {
178
$data = $this->
raw
(self::FIELD_SKU);
179
if
(is_null($data)) {
180
return
null
;
181
}
182
$this->sku = (string) $data;
183
}
184
185
return
$this->sku
;
186
}
187
194
public
function
getSlug
()
195
{
196
if
(is_null($this->slug)) {
198
$data = $this->
raw
(self::FIELD_SLUG);
199
if
(is_null($data)) {
200
return
null
;
201
}
202
203
$this->slug = LocalizedStringModel::of($data);
204
}
205
206
return
$this->slug
;
207
}
208
215
public
function
getContainerAndKey
()
216
{
217
if
(is_null($this->containerAndKey)) {
219
$data = $this->
raw
(self::FIELD_CONTAINER_AND_KEY);
220
if
(is_null($data)) {
221
return
null
;
222
}
223
224
$this->containerAndKey =
ContainerAndKeyModel::of
($data);
225
}
226
227
return
$this->containerAndKey
;
228
}
229
230
234
public
function
setKey
(?
string
$key
): void
235
{
236
$this->key =
$key
;
237
}
238
242
public
function
setExternalId
(?
string
$externalId
): void
243
{
244
$this->externalId =
$externalId
;
245
}
246
250
public
function
setOrderNumber
(?
string
$orderNumber
): void
251
{
252
$this->orderNumber =
$orderNumber
;
253
}
254
258
public
function
setCustomerNumber
(?
string
$customerNumber
): void
259
{
260
$this->customerNumber =
$customerNumber
;
261
}
262
266
public
function
setSku
(?
string
$sku
): void
267
{
268
$this->sku =
$sku
;
269
}
270
274
public
function
setSlug
(?
LocalizedString
$slug
): void
275
{
276
$this->slug =
$slug
;
277
}
278
282
public
function
setContainerAndKey
(?
ContainerAndKey
$containerAndKey
): void
283
{
284
$this->containerAndKey =
$containerAndKey
;
285
}
286
}
Commercetools\Api\Models\Common\LocalizedStringModel
Definition
LocalizedStringModel.php:17
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel
Definition
UserProvidedIdentifiersModel.php:23
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\$key
$key
Definition
UserProvidedIdentifiersModel.php:28
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\setSlug
setSlug(?LocalizedString $slug)
Definition
UserProvidedIdentifiersModel.php:274
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\setKey
setKey(?string $key)
Definition
UserProvidedIdentifiersModel.php:234
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\getExternalId
getExternalId()
Definition
UserProvidedIdentifiersModel.php:114
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\getSku
getSku()
Definition
UserProvidedIdentifiersModel.php:174
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\getCustomerNumber
getCustomerNumber()
Definition
UserProvidedIdentifiersModel.php:154
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\setOrderNumber
setOrderNumber(?string $orderNumber)
Definition
UserProvidedIdentifiersModel.php:250
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\setExternalId
setExternalId(?string $externalId)
Definition
UserProvidedIdentifiersModel.php:242
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\__construct
__construct(?string $key=null, ?string $externalId=null, ?string $orderNumber=null, ?string $customerNumber=null, ?string $sku=null, ?LocalizedString $slug=null, ?ContainerAndKey $containerAndKey=null)
Definition
UserProvidedIdentifiersModel.php:70
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\getOrderNumber
getOrderNumber()
Definition
UserProvidedIdentifiersModel.php:134
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\$orderNumber
$orderNumber
Definition
UserProvidedIdentifiersModel.php:40
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\$containerAndKey
$containerAndKey
Definition
UserProvidedIdentifiersModel.php:64
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\$slug
$slug
Definition
UserProvidedIdentifiersModel.php:58
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\getSlug
getSlug()
Definition
UserProvidedIdentifiersModel.php:194
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\$customerNumber
$customerNumber
Definition
UserProvidedIdentifiersModel.php:46
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\getContainerAndKey
getContainerAndKey()
Definition
UserProvidedIdentifiersModel.php:215
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\setCustomerNumber
setCustomerNumber(?string $customerNumber)
Definition
UserProvidedIdentifiersModel.php:258
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\getKey
getKey()
Definition
UserProvidedIdentifiersModel.php:94
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\setContainerAndKey
setContainerAndKey(?ContainerAndKey $containerAndKey)
Definition
UserProvidedIdentifiersModel.php:282
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\$externalId
$externalId
Definition
UserProvidedIdentifiersModel.php:34
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\setSku
setSku(?string $sku)
Definition
UserProvidedIdentifiersModel.php:266
Commercetools\Api\Models\Message\UserProvidedIdentifiersModel\$sku
$sku
Definition
UserProvidedIdentifiersModel.php:52
Commercetools\Base\BaseJsonObject\raw
raw(string $field)
Definition
BaseJsonObject.php:57
Commercetools\Base\BaseJsonObject\of
static of($data=null)
Definition
BaseJsonObject.php:26
Commercetools\Base\DateTimeImmutableCollection
Definition
DateTimeImmutableCollection.php:21
Commercetools\Base\JsonObjectModel
Definition
JsonObjectModel.php:15
Commercetools\Base\MapperFactory
Definition
MapperFactory.php:16
Commercetools\Api\Models\Common\LocalizedString
Definition
LocalizedString.php:14
Commercetools\Api\Models\Message\ContainerAndKey
Definition
ContainerAndKey.php:15
Commercetools\Api\Models\Message\UserProvidedIdentifiers
Definition
UserProvidedIdentifiers.php:16
Commercetools\Base\JsonObject
Definition
JsonObject.php:15
Commercetools\Api\Models\Message
Definition
ApprovalFlowApprovedMessage.php:9
Generated by
1.9.8