commercetools-sdk-php-v2
The commercetools platform, import-api and PHP sdks generated from our api reference.
lib
commercetools-import
src
Models
Common
ImportResourceModel.php
1
<?php
2
3
declare(strict_types=1);
9
namespace
Commercetools\Import\Models\Common
;
10
11
use
Commercetools\Base\DateTimeImmutableCollection
;
12
use
Commercetools\Base\JsonObject
;
13
use
Commercetools\Base\JsonObjectModel
;
14
use
Commercetools\Base\MapperFactory
;
15
use
Commercetools\Import\Models\Categories\CategoryImport
;
16
use
Commercetools\Import\Models\Categories\CategoryImportModel
;
17
use
Commercetools\Import\Models\Customers\CustomerImport
;
18
use
Commercetools\Import\Models\Customers\CustomerImportModel
;
19
use
Commercetools\Import\Models\DiscountCodes\DiscountCodeImport
;
20
use
Commercetools\Import\Models\DiscountCodes\DiscountCodeImportModel
;
21
use
Commercetools\Import\Models\Inventories\InventoryImport
;
22
use
Commercetools\Import\Models\Inventories\InventoryImportModel
;
23
use
Commercetools\Import\Models\Prices\PriceImport
;
24
use
Commercetools\Import\Models\Prices\PriceImportModel
;
25
use
Commercetools\Import\Models\Productdrafts\ProductDraftImport
;
26
use
Commercetools\Import\Models\Productdrafts\ProductDraftImportModel
;
27
use
Commercetools\Import\Models\Products\ProductImport
;
28
use
Commercetools\Import\Models\Products\ProductImportModel
;
29
use
Commercetools\Import\Models\Producttypes\ProductTypeImport
;
30
use
Commercetools\Import\Models\Producttypes\ProductTypeImportModel
;
31
use
Commercetools\Import\Models\Productvariants\ProductVariantImport
;
32
use
Commercetools\Import\Models\Productvariants\ProductVariantImportModel
;
33
use
Commercetools\Import\Models\StandalonePrices\StandalonePriceImport
;
34
use
Commercetools\Import\Models\StandalonePrices\StandalonePriceImportModel
;
35
use
Commercetools\Import\Models\Types\TypeImport
;
36
use
Commercetools\Import\Models\Types\TypeImportModel
;
37
use stdClass;
38
42
final
class
ImportResourceModel
extends
JsonObjectModel
implements
ImportResource
43
{
48
protected
$key
;
49
50
54
public
function
__construct
(
55
?
string
$key
=
null
56
) {
57
$this->key =
$key
;
58
}
59
66
public
function
getKey
()
67
{
68
if
(is_null($this->key)) {
70
$data = $this->
raw
(self::FIELD_KEY);
71
if
(is_null($data)) {
72
return
null
;
73
}
74
$this->key = (string) $data;
75
}
76
77
return
$this->key
;
78
}
79
80
84
public
function
setKey
(?
string
$key
): void
85
{
86
$this->key =
$key
;
87
}
88
}
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\Import\Models\Categories\CategoryImportModel
Definition:
CategoryImportModel.php:30
Commercetools\Import\Models\Common\ImportResourceModel
Definition:
ImportResourceModel.php:43
Commercetools\Import\Models\Common\ImportResourceModel\$key
$key
Definition:
ImportResourceModel.php:48
Commercetools\Import\Models\Common\ImportResourceModel\__construct
__construct(?string $key=null)
Definition:
ImportResourceModel.php:54
Commercetools\Import\Models\Common\ImportResourceModel\getKey
getKey()
Definition:
ImportResourceModel.php:66
Commercetools\Import\Models\Common\ImportResourceModel\setKey
setKey(?string $key)
Definition:
ImportResourceModel.php:84
Commercetools\Import\Models\Customers\CustomerImportModel
Definition:
CustomerImportModel.php:29
Commercetools\Import\Models\DiscountCodes\DiscountCodeImportModel
Definition:
DiscountCodeImportModel.php:29
Commercetools\Import\Models\Inventories\InventoryImportModel
Definition:
InventoryImportModel.php:28
Commercetools\Import\Models\Prices\PriceImportModel
Definition:
PriceImportModel.php:39
Commercetools\Import\Models\Productdrafts\ProductDraftImportModel
Definition:
ProductDraftImportModel.php:34
Commercetools\Import\Models\Products\ProductImportModel
Definition:
ProductImportModel.php:32
Commercetools\Import\Models\Producttypes\ProductTypeImportModel
Definition:
ProductTypeImportModel.php:23
Commercetools\Import\Models\Productvariants\ProductVariantImportModel
Definition:
ProductVariantImportModel.php:27
Commercetools\Import\Models\StandalonePrices\StandalonePriceImportModel
Definition:
StandalonePriceImportModel.php:35
Commercetools\Import\Models\Types\TypeImportModel
Definition:
TypeImportModel.php:25
Commercetools\Base\JsonObject
Definition:
JsonObject.php:15
Commercetools\Import\Models\Categories\CategoryImport
Definition:
CategoryImport.php:20
Commercetools\Import\Models\Common\ImportResource
Definition:
ImportResource.php:26
Commercetools\Import\Models\Customers\CustomerImport
Definition:
CustomerImport.php:20
Commercetools\Import\Models\DiscountCodes\DiscountCodeImport
Definition:
DiscountCodeImport.php:20
Commercetools\Import\Models\Inventories\InventoryImport
Definition:
InventoryImport.php:19
Commercetools\Import\Models\Prices\PriceImport
Definition:
PriceImport.php:25
Commercetools\Import\Models\Productdrafts\ProductDraftImport
Definition:
ProductDraftImport.php:22
Commercetools\Import\Models\Products\ProductImport
Definition:
ProductImport.php:21
Commercetools\Import\Models\Producttypes\ProductTypeImport
Definition:
ProductTypeImport.php:16
Commercetools\Import\Models\Productvariants\ProductVariantImport
Definition:
ProductVariantImport.php:19
Commercetools\Import\Models\StandalonePrices\StandalonePriceImport
Definition:
StandalonePriceImport.php:23
Commercetools\Import\Models\Types\TypeImport
Definition:
TypeImport.php:17
Commercetools\Import\Models\Common
Definition:
Address.php:9
Generated by
1.9.1