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
Subscription
ResourceUpdatedDeliveryPayloadBuilder.php
1
<?php
2
3
declare(strict_types=1);
9
namespace
Commercetools\Api\Models\Subscription
;
10
11
use
Commercetools\Api\Models\Common\Reference
;
12
use
Commercetools\Api\Models\Common\ReferenceBuilder
;
13
use
Commercetools\Api\Models\Message\UserProvidedIdentifiers
;
14
use
Commercetools\Api\Models\Message\UserProvidedIdentifiersBuilder
;
15
use
Commercetools\Base\Builder
;
16
use
Commercetools\Base\DateTimeImmutableCollection
;
17
use
Commercetools\Base\JsonObject
;
18
use
Commercetools\Base\JsonObjectModel
;
19
use
Commercetools\Base\MapperFactory
;
20
use DateTimeImmutable;
21
use stdClass;
22
26
final
class
ResourceUpdatedDeliveryPayloadBuilder
implements
Builder
27
{
32
private
$projectKey;
33
38
private
$resource;
39
44
private
$resourceUserProvidedIdentifiers;
45
50
private
$version;
51
56
private
$oldVersion;
57
62
private
$modifiedAt;
63
71
public
function
getProjectKey
()
72
{
73
return
$this->projectKey;
74
}
75
82
public
function
getResource
()
83
{
84
return
$this->resource instanceof
ReferenceBuilder
? $this->resource->
build
() : $this->resource;
85
}
86
93
public
function
getResourceUserProvidedIdentifiers
()
94
{
95
return
$this->resourceUserProvidedIdentifiers instanceof
UserProvidedIdentifiersBuilder
? $this->resourceUserProvidedIdentifiers->
build
() : $this->resourceUserProvidedIdentifiers;
96
}
97
104
public
function
getVersion
()
105
{
106
return
$this->version;
107
}
108
115
public
function
getOldVersion
()
116
{
117
return
$this->oldVersion;
118
}
119
126
public
function
getModifiedAt
()
127
{
128
return
$this->modifiedAt;
129
}
130
135
public
function
withProjectKey
(?
string
$projectKey)
136
{
137
$this->projectKey = $projectKey;
138
139
return
$this;
140
}
141
146
public
function
withResource
(?
Reference
$resource)
147
{
148
$this->resource = $resource;
149
150
return
$this;
151
}
152
157
public
function
withResourceUserProvidedIdentifiers
(?
UserProvidedIdentifiers
$resourceUserProvidedIdentifiers)
158
{
159
$this->resourceUserProvidedIdentifiers = $resourceUserProvidedIdentifiers;
160
161
return
$this;
162
}
163
168
public
function
withVersion
(?
int
$version)
169
{
170
$this->version = $version;
171
172
return
$this;
173
}
174
179
public
function
withOldVersion
(?
int
$oldVersion)
180
{
181
$this->oldVersion = $oldVersion;
182
183
return
$this;
184
}
185
190
public
function
withModifiedAt
(?DateTimeImmutable $modifiedAt)
191
{
192
$this->modifiedAt = $modifiedAt;
193
194
return
$this;
195
}
196
201
public
function
withResourceBuilder
(?
ReferenceBuilder
$resource)
202
{
203
$this->resource = $resource;
204
205
return
$this;
206
}
207
212
public
function
withResourceUserProvidedIdentifiersBuilder
(?
UserProvidedIdentifiersBuilder
$resourceUserProvidedIdentifiers)
213
{
214
$this->resourceUserProvidedIdentifiers = $resourceUserProvidedIdentifiers;
215
216
return
$this;
217
}
218
219
public
function
build
():
ResourceUpdatedDeliveryPayload
220
{
221
return
new
ResourceUpdatedDeliveryPayloadModel
(
222
$this->projectKey,
223
$this->resource instanceof
ReferenceBuilder
? $this->resource->
build
() : $this->resource,
224
$this->resourceUserProvidedIdentifiers instanceof
UserProvidedIdentifiersBuilder
? $this->resourceUserProvidedIdentifiers->
build
() : $this->resourceUserProvidedIdentifiers,
225
$this->version,
226
$this->oldVersion,
227
$this->modifiedAt
228
);
229
}
230
231
public
static
function
of
():
ResourceUpdatedDeliveryPayloadBuilder
232
{
233
return
new
self
();
234
}
235
}
Commercetools\Api\Models\Common\ReferenceBuilder
Definition
ReferenceBuilder.php:92
Commercetools\Api\Models\Common\ReferenceBuilder\build
build()
Definition
ReferenceBuilder.php:122
Commercetools\Api\Models\Message\UserProvidedIdentifiersBuilder
Definition
UserProvidedIdentifiersBuilder.php:24
Commercetools\Api\Models\Message\UserProvidedIdentifiersBuilder\build
build()
Definition
UserProvidedIdentifiersBuilder.php:243
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:27
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\build
build()
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:219
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\withProjectKey
withProjectKey(?string $projectKey)
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:135
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\withResourceUserProvidedIdentifiersBuilder
withResourceUserProvidedIdentifiersBuilder(?UserProvidedIdentifiersBuilder $resourceUserProvidedIdentifiers)
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:212
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\withResourceUserProvidedIdentifiers
withResourceUserProvidedIdentifiers(?UserProvidedIdentifiers $resourceUserProvidedIdentifiers)
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:157
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\withVersion
withVersion(?int $version)
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:168
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\getResourceUserProvidedIdentifiers
getResourceUserProvidedIdentifiers()
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:93
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\withOldVersion
withOldVersion(?int $oldVersion)
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:179
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\withResourceBuilder
withResourceBuilder(?ReferenceBuilder $resource)
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:201
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\getModifiedAt
getModifiedAt()
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:126
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\of
static of()
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:231
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\getOldVersion
getOldVersion()
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:115
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\getVersion
getVersion()
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:104
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\getResource
getResource()
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:82
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\withResource
withResource(?Reference $resource)
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:146
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\getProjectKey
getProjectKey()
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:71
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadBuilder\withModifiedAt
withModifiedAt(?DateTimeImmutable $modifiedAt)
Definition
ResourceUpdatedDeliveryPayloadBuilder.php:190
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayloadModel
Definition
ResourceUpdatedDeliveryPayloadModel.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\Reference
Definition
Reference.php:50
Commercetools\Api\Models\Message\UserProvidedIdentifiers
Definition
UserProvidedIdentifiers.php:16
Commercetools\Api\Models\Subscription\ResourceUpdatedDeliveryPayload
Definition
ResourceUpdatedDeliveryPayload.php:16
Commercetools\Base\Builder
Definition
Builder.php:16
Commercetools\Base\JsonObject
Definition
JsonObject.php:15
Commercetools\Api\Models\Subscription
Definition
AzureEventGridDestination.php:9
Generated by
1.9.8