commercetools-sdk-php-v2
The commercetools platform, import-api and PHP sdks generated from our api reference.
Loading...
Searching...
No Matches
OrderCustomerSetMessageBuilder.php
1<?php
2
3declare(strict_types=1);
10
26use DateTimeImmutable;
27use stdClass;
28
33{
38 private $id;
39
44 private $version;
45
50 private $createdAt;
51
56 private $lastModifiedAt;
57
62 private $lastModifiedBy;
63
68 private $createdBy;
69
74 private $sequenceNumber;
75
80 private $resource;
81
86 private $resourceVersion;
87
92 private $resourceUserProvidedIdentifiers;
93
98 private $customer;
99
104 private $customerGroup;
105
110 private $oldCustomer;
111
116 private $oldCustomerGroup;
117
124 public function getId()
125 {
126 return $this->id;
127 }
128
135 public function getVersion()
136 {
137 return $this->version;
138 }
139
146 public function getCreatedAt()
147 {
148 return $this->createdAt;
149 }
150
157 public function getLastModifiedAt()
158 {
159 return $this->lastModifiedAt;
160 }
161
168 public function getLastModifiedBy()
169 {
170 return $this->lastModifiedBy instanceof LastModifiedByBuilder ? $this->lastModifiedBy->build() : $this->lastModifiedBy;
171 }
172
179 public function getCreatedBy()
180 {
181 return $this->createdBy instanceof CreatedByBuilder ? $this->createdBy->build() : $this->createdBy;
182 }
183
191 public function getSequenceNumber()
192 {
193 return $this->sequenceNumber;
194 }
195
202 public function getResource()
203 {
204 return $this->resource instanceof ReferenceBuilder ? $this->resource->build() : $this->resource;
205 }
206
213 public function getResourceVersion()
214 {
215 return $this->resourceVersion;
216 }
217
225 {
226 return $this->resourceUserProvidedIdentifiers instanceof UserProvidedIdentifiersBuilder ? $this->resourceUserProvidedIdentifiers->build() : $this->resourceUserProvidedIdentifiers;
227 }
228
235 public function getCustomer()
236 {
237 return $this->customer instanceof CustomerReferenceBuilder ? $this->customer->build() : $this->customer;
238 }
239
246 public function getCustomerGroup()
247 {
248 return $this->customerGroup instanceof CustomerGroupReferenceBuilder ? $this->customerGroup->build() : $this->customerGroup;
249 }
250
257 public function getOldCustomer()
258 {
259 return $this->oldCustomer instanceof CustomerReferenceBuilder ? $this->oldCustomer->build() : $this->oldCustomer;
260 }
261
268 public function getOldCustomerGroup()
269 {
270 return $this->oldCustomerGroup instanceof CustomerGroupReferenceBuilder ? $this->oldCustomerGroup->build() : $this->oldCustomerGroup;
271 }
272
277 public function withId(?string $id)
278 {
279 $this->id = $id;
280
281 return $this;
282 }
283
288 public function withVersion(?int $version)
289 {
290 $this->version = $version;
291
292 return $this;
293 }
294
299 public function withCreatedAt(?DateTimeImmutable $createdAt)
300 {
301 $this->createdAt = $createdAt;
302
303 return $this;
304 }
305
310 public function withLastModifiedAt(?DateTimeImmutable $lastModifiedAt)
311 {
312 $this->lastModifiedAt = $lastModifiedAt;
313
314 return $this;
315 }
316
321 public function withLastModifiedBy(?LastModifiedBy $lastModifiedBy)
322 {
323 $this->lastModifiedBy = $lastModifiedBy;
324
325 return $this;
326 }
327
332 public function withCreatedBy(?CreatedBy $createdBy)
333 {
334 $this->createdBy = $createdBy;
335
336 return $this;
337 }
338
343 public function withSequenceNumber(?int $sequenceNumber)
344 {
345 $this->sequenceNumber = $sequenceNumber;
346
347 return $this;
348 }
349
354 public function withResource(?Reference $resource)
355 {
356 $this->resource = $resource;
357
358 return $this;
359 }
360
365 public function withResourceVersion(?int $resourceVersion)
366 {
367 $this->resourceVersion = $resourceVersion;
368
369 return $this;
370 }
371
376 public function withResourceUserProvidedIdentifiers(?UserProvidedIdentifiers $resourceUserProvidedIdentifiers)
377 {
378 $this->resourceUserProvidedIdentifiers = $resourceUserProvidedIdentifiers;
379
380 return $this;
381 }
382
387 public function withCustomer(?CustomerReference $customer)
388 {
389 $this->customer = $customer;
390
391 return $this;
392 }
393
398 public function withCustomerGroup(?CustomerGroupReference $customerGroup)
399 {
400 $this->customerGroup = $customerGroup;
401
402 return $this;
403 }
404
409 public function withOldCustomer(?CustomerReference $oldCustomer)
410 {
411 $this->oldCustomer = $oldCustomer;
412
413 return $this;
414 }
415
420 public function withOldCustomerGroup(?CustomerGroupReference $oldCustomerGroup)
421 {
422 $this->oldCustomerGroup = $oldCustomerGroup;
423
424 return $this;
425 }
426
431 public function withLastModifiedByBuilder(?LastModifiedByBuilder $lastModifiedBy)
432 {
433 $this->lastModifiedBy = $lastModifiedBy;
434
435 return $this;
436 }
437
442 public function withCreatedByBuilder(?CreatedByBuilder $createdBy)
443 {
444 $this->createdBy = $createdBy;
445
446 return $this;
447 }
448
453 public function withResourceBuilder(?ReferenceBuilder $resource)
454 {
455 $this->resource = $resource;
456
457 return $this;
458 }
459
464 public function withResourceUserProvidedIdentifiersBuilder(?UserProvidedIdentifiersBuilder $resourceUserProvidedIdentifiers)
465 {
466 $this->resourceUserProvidedIdentifiers = $resourceUserProvidedIdentifiers;
467
468 return $this;
469 }
470
476 {
477 $this->customer = $customer;
478
479 return $this;
480 }
481
487 {
488 $this->customerGroup = $customerGroup;
489
490 return $this;
491 }
492
498 {
499 $this->oldCustomer = $oldCustomer;
500
501 return $this;
502 }
503
509 {
510 $this->oldCustomerGroup = $oldCustomerGroup;
511
512 return $this;
513 }
514
516 {
518 $this->id,
519 $this->version,
520 $this->createdAt,
521 $this->lastModifiedAt,
522 $this->lastModifiedBy instanceof LastModifiedByBuilder ? $this->lastModifiedBy->build() : $this->lastModifiedBy,
523 $this->createdBy instanceof CreatedByBuilder ? $this->createdBy->build() : $this->createdBy,
524 $this->sequenceNumber,
525 $this->resource instanceof ReferenceBuilder ? $this->resource->build() : $this->resource,
526 $this->resourceVersion,
527 $this->resourceUserProvidedIdentifiers instanceof UserProvidedIdentifiersBuilder ? $this->resourceUserProvidedIdentifiers->build() : $this->resourceUserProvidedIdentifiers,
528 $this->customer instanceof CustomerReferenceBuilder ? $this->customer->build() : $this->customer,
529 $this->customerGroup instanceof CustomerGroupReferenceBuilder ? $this->customerGroup->build() : $this->customerGroup,
530 $this->oldCustomer instanceof CustomerReferenceBuilder ? $this->oldCustomer->build() : $this->oldCustomer,
531 $this->oldCustomerGroup instanceof CustomerGroupReferenceBuilder ? $this->oldCustomerGroup->build() : $this->oldCustomerGroup
532 );
533 }
534
535 public static function of(): OrderCustomerSetMessageBuilder
536 {
537 return new self();
538 }
539}
withResourceUserProvidedIdentifiersBuilder(?UserProvidedIdentifiersBuilder $resourceUserProvidedIdentifiers)
withOldCustomerGroupBuilder(?CustomerGroupReferenceBuilder $oldCustomerGroup)
withResourceUserProvidedIdentifiers(?UserProvidedIdentifiers $resourceUserProvidedIdentifiers)