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
Me
MyBusinessUnitAssociateDraftBuilder.php
1
<?php
2
3
declare(strict_types=1);
9
namespace
Commercetools\Api\Models\Me
;
10
11
use
Commercetools\Api\Models\BusinessUnit\AssociateRoleAssignmentDraftCollection
;
12
use
Commercetools\Base\Builder
;
13
use
Commercetools\Base\DateTimeImmutableCollection
;
14
use
Commercetools\Base\JsonObject
;
15
use
Commercetools\Base\JsonObjectModel
;
16
use
Commercetools\Base\MapperFactory
;
17
use stdClass;
18
22
final
class
MyBusinessUnitAssociateDraftBuilder
implements
Builder
23
{
28
private
$version;
29
34
private
$customer;
35
40
private
$associateRoleAssignments;
41
49
public
function
getVersion
()
50
{
51
return
$this->version;
52
}
53
60
public
function
getCustomer
()
61
{
62
return
$this->customer instanceof
MyCustomerDraftBuilder
? $this->customer->
build
() : $this->customer;
63
}
64
71
public
function
getAssociateRoleAssignments
()
72
{
73
return
$this->associateRoleAssignments;
74
}
75
80
public
function
withVersion
(?
int
$version)
81
{
82
$this->version = $version;
83
84
return
$this;
85
}
86
91
public
function
withCustomer
(?
MyCustomerDraft
$customer)
92
{
93
$this->customer = $customer;
94
95
return
$this;
96
}
97
102
public
function
withAssociateRoleAssignments
(?
AssociateRoleAssignmentDraftCollection
$associateRoleAssignments)
103
{
104
$this->associateRoleAssignments = $associateRoleAssignments;
105
106
return
$this;
107
}
108
113
public
function
withCustomerBuilder
(?
MyCustomerDraftBuilder
$customer)
114
{
115
$this->customer = $customer;
116
117
return
$this;
118
}
119
120
public
function
build
():
MyBusinessUnitAssociateDraft
121
{
122
return
new
MyBusinessUnitAssociateDraftModel
(
123
$this->version,
124
$this->customer instanceof
MyCustomerDraftBuilder
? $this->customer->
build
() : $this->customer,
125
$this->associateRoleAssignments
126
);
127
}
128
129
public
static
function
of
():
MyBusinessUnitAssociateDraftBuilder
130
{
131
return
new
self
();
132
}
133
}
Commercetools\Api\Models\BusinessUnit\AssociateRoleAssignmentDraftCollection
Definition
AssociateRoleAssignmentDraftCollection.php:22
Commercetools\Api\Models\Me\MyBusinessUnitAssociateDraftBuilder
Definition
MyBusinessUnitAssociateDraftBuilder.php:23
Commercetools\Api\Models\Me\MyBusinessUnitAssociateDraftBuilder\withCustomerBuilder
withCustomerBuilder(?MyCustomerDraftBuilder $customer)
Definition
MyBusinessUnitAssociateDraftBuilder.php:113
Commercetools\Api\Models\Me\MyBusinessUnitAssociateDraftBuilder\getCustomer
getCustomer()
Definition
MyBusinessUnitAssociateDraftBuilder.php:60
Commercetools\Api\Models\Me\MyBusinessUnitAssociateDraftBuilder\build
build()
Definition
MyBusinessUnitAssociateDraftBuilder.php:120
Commercetools\Api\Models\Me\MyBusinessUnitAssociateDraftBuilder\getVersion
getVersion()
Definition
MyBusinessUnitAssociateDraftBuilder.php:49
Commercetools\Api\Models\Me\MyBusinessUnitAssociateDraftBuilder\getAssociateRoleAssignments
getAssociateRoleAssignments()
Definition
MyBusinessUnitAssociateDraftBuilder.php:71
Commercetools\Api\Models\Me\MyBusinessUnitAssociateDraftBuilder\of
static of()
Definition
MyBusinessUnitAssociateDraftBuilder.php:129
Commercetools\Api\Models\Me\MyBusinessUnitAssociateDraftBuilder\withVersion
withVersion(?int $version)
Definition
MyBusinessUnitAssociateDraftBuilder.php:80
Commercetools\Api\Models\Me\MyBusinessUnitAssociateDraftBuilder\withCustomer
withCustomer(?MyCustomerDraft $customer)
Definition
MyBusinessUnitAssociateDraftBuilder.php:91
Commercetools\Api\Models\Me\MyBusinessUnitAssociateDraftBuilder\withAssociateRoleAssignments
withAssociateRoleAssignments(?AssociateRoleAssignmentDraftCollection $associateRoleAssignments)
Definition
MyBusinessUnitAssociateDraftBuilder.php:102
Commercetools\Api\Models\Me\MyBusinessUnitAssociateDraftModel
Definition
MyBusinessUnitAssociateDraftModel.php:22
Commercetools\Api\Models\Me\MyCustomerDraftBuilder
Definition
MyCustomerDraftBuilder.php:27
Commercetools\Api\Models\Me\MyCustomerDraftBuilder\build
build()
Definition
MyCustomerDraftBuilder.php:490
Commercetools\Base\DateTimeImmutableCollection
Definition
DateTimeImmutableCollection.php:21
Commercetools\Base\JsonObjectModel
Definition
JsonObjectModel.php:15
Commercetools\Base\MapperFactory
Definition
MapperFactory.php:16
Commercetools\Api\Models\Me\MyBusinessUnitAssociateDraft
Definition
MyBusinessUnitAssociateDraft.php:16
Commercetools\Api\Models\Me\MyCustomerDraft
Definition
MyCustomerDraft.php:19
Commercetools\Base\Builder
Definition
Builder.php:16
Commercetools\Base\JsonObject
Definition
JsonObject.php:15
Commercetools\Api\Models\Me
Definition
MyBusinessUnitAddAddressAction.php:9
Generated by
1.9.8