3 declare(strict_types=1);
37 use DateTimeImmutable;
405 if (is_null($this->
id)) {
407 $data = $this->
raw(self::FIELD_ID);
408 if (is_null($data)) {
411 $this->
id = (string) $data;
425 if (is_null($this->version)) {
427 $data = $this->
raw(self::FIELD_VERSION);
428 if (is_null($data)) {
431 $this->version = (int) $data;
445 if (is_null($this->createdAt)) {
447 $data = $this->
raw(self::FIELD_CREATED_AT);
448 if (is_null($data)) {
452 if (
false === $data) {
455 $this->createdAt = $data;
469 if (is_null($this->lastModifiedAt)) {
471 $data = $this->
raw(self::FIELD_LAST_MODIFIED_AT);
472 if (is_null($data)) {
476 if (
false === $data) {
479 $this->lastModifiedAt = $data;
493 if (is_null($this->key)) {
495 $data = $this->
raw(self::FIELD_KEY);
496 if (is_null($data)) {
499 $this->key = (string) $data;
513 if (is_null($this->customerId)) {
515 $data = $this->
raw(self::FIELD_CUSTOMER_ID);
516 if (is_null($data)) {
519 $this->customerId = (string) $data;
533 if (is_null($this->customerEmail)) {
535 $data = $this->
raw(self::FIELD_CUSTOMER_EMAIL);
536 if (is_null($data)) {
539 $this->customerEmail = (string) $data;
553 if (is_null($this->customerGroup)) {
555 $data = $this->
raw(self::FIELD_CUSTOMER_GROUP);
556 if (is_null($data)) {
574 if (is_null($this->anonymousId)) {
576 $data = $this->
raw(self::FIELD_ANONYMOUS_ID);
577 if (is_null($data)) {
580 $this->anonymousId = (string) $data;
594 if (is_null($this->businessUnit)) {
596 $data = $this->
raw(self::FIELD_BUSINESS_UNIT);
597 if (is_null($data)) {
615 if (is_null($this->store)) {
617 $data = $this->
raw(self::FIELD_STORE);
618 if (is_null($data)) {
636 if (is_null($this->lineItems)) {
638 $data = $this->
raw(self::FIELD_LINE_ITEMS);
639 if (is_null($data)) {
656 if (is_null($this->customLineItems)) {
658 $data = $this->
raw(self::FIELD_CUSTOM_LINE_ITEMS);
659 if (is_null($data)) {
676 if (is_null($this->totalLineItemQuantity)) {
678 $data = $this->
raw(self::FIELD_TOTAL_LINE_ITEM_QUANTITY);
679 if (is_null($data)) {
682 $this->totalLineItemQuantity = (int) $data;
698 if (is_null($this->totalPrice)) {
700 $data = $this->
raw(self::FIELD_TOTAL_PRICE);
701 if (is_null($data)) {
723 if (is_null($this->taxedPrice)) {
725 $data = $this->
raw(self::FIELD_TAXED_PRICE);
726 if (is_null($data)) {
744 if (is_null($this->taxedShippingPrice)) {
746 $data = $this->
raw(self::FIELD_TAXED_SHIPPING_PRICE);
747 if (is_null($data)) {
765 if (is_null($this->discountOnTotalPrice)) {
767 $data = $this->
raw(self::FIELD_DISCOUNT_ON_TOTAL_PRICE);
768 if (is_null($data)) {
786 if (is_null($this->taxMode)) {
788 $data = $this->
raw(self::FIELD_TAX_MODE);
789 if (is_null($data)) {
792 $this->taxMode = (string) $data;
806 if (is_null($this->taxRoundingMode)) {
808 $data = $this->
raw(self::FIELD_TAX_ROUNDING_MODE);
809 if (is_null($data)) {
812 $this->taxRoundingMode = (string) $data;
826 if (is_null($this->taxCalculationMode)) {
828 $data = $this->
raw(self::FIELD_TAX_CALCULATION_MODE);
829 if (is_null($data)) {
832 $this->taxCalculationMode = (string) $data;
846 if (is_null($this->inventoryMode)) {
848 $data = $this->
raw(self::FIELD_INVENTORY_MODE);
849 if (is_null($data)) {
852 $this->inventoryMode = (string) $data;
866 if (is_null($this->cartState)) {
868 $data = $this->
raw(self::FIELD_CART_STATE);
869 if (is_null($data)) {
872 $this->cartState = (string) $data;
886 if (is_null($this->billingAddress)) {
888 $data = $this->
raw(self::FIELD_BILLING_ADDRESS);
889 if (is_null($data)) {
907 if (is_null($this->shippingAddress)) {
909 $data = $this->
raw(self::FIELD_SHIPPING_ADDRESS);
910 if (is_null($data)) {
928 if (is_null($this->shippingMode)) {
930 $data = $this->
raw(self::FIELD_SHIPPING_MODE);
931 if (is_null($data)) {
934 $this->shippingMode = (string) $data;
948 if (is_null($this->shippingKey)) {
950 $data = $this->
raw(self::FIELD_SHIPPING_KEY);
951 if (is_null($data)) {
954 $this->shippingKey = (string) $data;
968 if (is_null($this->shippingInfo)) {
970 $data = $this->
raw(self::FIELD_SHIPPING_INFO);
971 if (is_null($data)) {
995 if (is_null($this->shippingRateInput)) {
997 $data = $this->
raw(self::FIELD_SHIPPING_RATE_INPUT);
998 if (is_null($data)) {
1002 $this->shippingRateInput = $className::of($data);
1016 if (is_null($this->shippingCustomFields)) {
1018 $data = $this->
raw(self::FIELD_SHIPPING_CUSTOM_FIELDS);
1019 if (is_null($data)) {
1037 if (is_null($this->shipping)) {
1039 $data = $this->
raw(self::FIELD_SHIPPING);
1040 if (is_null($data)) {
1058 if (is_null($this->itemShippingAddresses)) {
1060 $data = $this->
raw(self::FIELD_ITEM_SHIPPING_ADDRESSES);
1061 if (is_null($data)) {
1078 if (is_null($this->discountCodes)) {
1080 $data = $this->
raw(self::FIELD_DISCOUNT_CODES);
1081 if (is_null($data)) {
1098 if (is_null($this->directDiscounts)) {
1100 $data = $this->
raw(self::FIELD_DIRECT_DISCOUNTS);
1101 if (is_null($data)) {
1118 if (is_null($this->refusedGifts)) {
1120 $data = $this->
raw(self::FIELD_REFUSED_GIFTS);
1121 if (is_null($data)) {
1138 if (is_null($this->paymentInfo)) {
1140 $data = $this->
raw(self::FIELD_PAYMENT_INFO);
1141 if (is_null($data)) {
1159 if (is_null($this->country)) {
1161 $data = $this->
raw(self::FIELD_COUNTRY);
1162 if (is_null($data)) {
1165 $this->country = (string) $data;
1179 if (is_null($this->locale)) {
1181 $data = $this->
raw(self::FIELD_LOCALE);
1182 if (is_null($data)) {
1185 $this->locale = (string) $data;
1199 if (is_null($this->origin)) {
1201 $data = $this->
raw(self::FIELD_ORIGIN);
1202 if (is_null($data)) {
1205 $this->origin = (string) $data;
1219 if (is_null($this->custom)) {
1221 $data = $this->
raw(self::FIELD_CUSTOM);
1222 if (is_null($data)) {
1240 if (is_null($this->deleteDaysAfterLastModification)) {
1242 $data = $this->
raw(self::FIELD_DELETE_DAYS_AFTER_LAST_MODIFICATION);
1243 if (is_null($data)) {
1246 $this->deleteDaysAfterLastModification = (int) $data;
1260 if (is_null($this->lastModifiedBy)) {
1262 $data = $this->
raw(self::FIELD_LAST_MODIFIED_BY);
1263 if (is_null($data)) {
1281 if (is_null($this->createdBy)) {
1283 $data = $this->
raw(self::FIELD_CREATED_BY);
1284 if (is_null($data)) {
1640 #[\ReturnTypeWillChange]
1651 return (
object) $data;
__construct(?string $id=null, ?int $version=null, ?DateTimeImmutable $createdAt=null, ?DateTimeImmutable $lastModifiedAt=null, ?string $key=null, ?string $customerId=null, ?string $customerEmail=null, ?CustomerGroupReference $customerGroup=null, ?string $anonymousId=null, ?BusinessUnitKeyReference $businessUnit=null, ?StoreKeyReference $store=null, ?LineItemCollection $lineItems=null, ?CustomLineItemCollection $customLineItems=null, ?int $totalLineItemQuantity=null, ?CentPrecisionMoney $totalPrice=null, ?TaxedPrice $taxedPrice=null, ?TaxedPrice $taxedShippingPrice=null, ?DiscountOnTotalPrice $discountOnTotalPrice=null, ?string $taxMode=null, ?string $taxRoundingMode=null, ?string $taxCalculationMode=null, ?string $inventoryMode=null, ?string $cartState=null, ?Address $billingAddress=null, ?Address $shippingAddress=null, ?string $shippingMode=null, ?string $shippingKey=null, ?ShippingInfo $shippingInfo=null, ?ShippingRateInput $shippingRateInput=null, ?CustomFields $shippingCustomFields=null, ?ShippingCollection $shipping=null, ?AddressCollection $itemShippingAddresses=null, ?DiscountCodeInfoCollection $discountCodes=null, ?DirectDiscountCollection $directDiscounts=null, ?CartDiscountReferenceCollection $refusedGifts=null, ?PaymentInfo $paymentInfo=null, ?string $country=null, ?string $locale=null, ?string $origin=null, ?CustomFields $custom=null, ?int $deleteDaysAfterLastModification=null, ?LastModifiedBy $lastModifiedBy=null, ?CreatedBy $createdBy=null)