commercetools-sdk-php-v2
The commercetools platform, import-api and PHP sdks generated from our api reference.
lib
commercetools-api
src
Models
BusinessUnit
BusinessUnitChangeAddressActionBuilder.php
1
<?php
2
3
declare(strict_types=1);
9
namespace
Commercetools\Api\Models\BusinessUnit
;
10
11
use
Commercetools\Api\Models\Common\BaseAddress
;
12
use
Commercetools\Api\Models\Common\BaseAddressBuilder
;
13
use
Commercetools\Base\Builder
;
14
use
Commercetools\Base\DateTimeImmutableCollection
;
15
use
Commercetools\Base\JsonObject
;
16
use
Commercetools\Base\JsonObjectModel
;
17
use
Commercetools\Base\MapperFactory
;
18
use stdClass;
19
23
final
class
BusinessUnitChangeAddressActionBuilder
implements
Builder
24
{
29
private
$addressId;
30
35
private
$addressKey;
36
41
private
$address;
42
49
public
function
getAddressId
()
50
{
51
return
$this->addressId;
52
}
53
60
public
function
getAddressKey
()
61
{
62
return
$this->addressKey;
63
}
64
71
public
function
getAddress
()
72
{
73
return
$this->address instanceof
BaseAddressBuilder
? $this->address->
build
() : $this->address;
74
}
75
80
public
function
withAddressId
(?
string
$addressId)
81
{
82
$this->addressId = $addressId;
83
84
return
$this;
85
}
86
91
public
function
withAddressKey
(?
string
$addressKey)
92
{
93
$this->addressKey = $addressKey;
94
95
return
$this;
96
}
97
102
public
function
withAddress
(?
BaseAddress
$address)
103
{
104
$this->address = $address;
105
106
return
$this;
107
}
108
113
public
function
withAddressBuilder
(?
BaseAddressBuilder
$address)
114
{
115
$this->address = $address;
116
117
return
$this;
118
}
119
120
public
function
build
():
BusinessUnitChangeAddressAction
121
{
122
return
new
BusinessUnitChangeAddressActionModel
(
123
$this->addressId,
124
$this->addressKey,
125
$this->address instanceof
BaseAddressBuilder
? $this->address->
build
() : $this->address
126
);
127
}
128
129
public
static
function
of
():
BusinessUnitChangeAddressActionBuilder
130
{
131
return
new
self
();
132
}
133
}
Commercetools\Api\Models\BusinessUnit\BusinessUnitChangeAddressActionBuilder
Definition:
BusinessUnitChangeAddressActionBuilder.php:24
Commercetools\Api\Models\BusinessUnit\BusinessUnitChangeAddressActionBuilder\of
static of()
Definition:
BusinessUnitChangeAddressActionBuilder.php:129
Commercetools\Api\Models\BusinessUnit\BusinessUnitChangeAddressActionBuilder\withAddressKey
withAddressKey(?string $addressKey)
Definition:
BusinessUnitChangeAddressActionBuilder.php:91
Commercetools\Api\Models\BusinessUnit\BusinessUnitChangeAddressActionBuilder\withAddress
withAddress(?BaseAddress $address)
Definition:
BusinessUnitChangeAddressActionBuilder.php:102
Commercetools\Api\Models\BusinessUnit\BusinessUnitChangeAddressActionBuilder\withAddressId
withAddressId(?string $addressId)
Definition:
BusinessUnitChangeAddressActionBuilder.php:80
Commercetools\Api\Models\BusinessUnit\BusinessUnitChangeAddressActionBuilder\getAddressKey
getAddressKey()
Definition:
BusinessUnitChangeAddressActionBuilder.php:60
Commercetools\Api\Models\BusinessUnit\BusinessUnitChangeAddressActionBuilder\getAddressId
getAddressId()
Definition:
BusinessUnitChangeAddressActionBuilder.php:49
Commercetools\Api\Models\BusinessUnit\BusinessUnitChangeAddressActionBuilder\withAddressBuilder
withAddressBuilder(?BaseAddressBuilder $address)
Definition:
BusinessUnitChangeAddressActionBuilder.php:113
Commercetools\Api\Models\BusinessUnit\BusinessUnitChangeAddressActionBuilder\getAddress
getAddress()
Definition:
BusinessUnitChangeAddressActionBuilder.php:71
Commercetools\Api\Models\BusinessUnit\BusinessUnitChangeAddressActionBuilder\build
build()
Definition:
BusinessUnitChangeAddressActionBuilder.php:120
Commercetools\Api\Models\BusinessUnit\BusinessUnitChangeAddressActionModel
Definition:
BusinessUnitChangeAddressActionModel.php:23
Commercetools\Api\Models\Common\BaseAddressBuilder
Definition:
BaseAddressBuilder.php:22
Commercetools\Api\Models\Common\BaseAddressBuilder\build
build()
Definition:
BaseAddressBuilder.php:726
Commercetools\Base\DateTimeImmutableCollection
Definition:
DateTimeImmutableCollection.php:21
Commercetools\Base\JsonObjectModel
Definition:
JsonObjectModel.php:15
Commercetools\Base\MapperFactory
Definition:
MapperFactory.php:16
Commercetools\Api\Models\BusinessUnit\BusinessUnitChangeAddressAction
Definition:
BusinessUnitChangeAddressAction.php:16
Commercetools\Api\Models\Common\BaseAddress
Definition:
BaseAddress.php:15
Commercetools\Base\Builder
Definition:
Builder.php:16
Commercetools\Base\JsonObject
Definition:
JsonObject.php:15
Commercetools\Api\Models\BusinessUnit
Definition:
Associate.php:9
Generated by
1.9.1