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
Customer
CustomerSigninBuilder.php
1
<?php
2
3
declare(strict_types=1);
9
namespace
Commercetools\Api\Models\Customer
;
10
11
use
Commercetools\Api\Models\Cart\CartResourceIdentifier
;
12
use
Commercetools\Api\Models\Cart\CartResourceIdentifierBuilder
;
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
CustomerSigninBuilder
implements
Builder
24
{
29
private
$email;
30
35
private
$password;
36
41
private
$anonymousCartId;
42
47
private
$anonymousCart;
48
53
private
$anonymousCartSignInMode;
54
59
private
$anonymousId;
60
65
private
$updateProductData;
66
73
public
function
getEmail
()
74
{
75
return
$this->email;
76
}
77
84
public
function
getPassword
()
85
{
86
return
$this->password;
87
}
88
95
public
function
getAnonymousCartId
()
96
{
97
return
$this->anonymousCartId;
98
}
99
106
public
function
getAnonymousCart
()
107
{
108
return
$this->anonymousCart instanceof
CartResourceIdentifierBuilder
? $this->anonymousCart->
build
() : $this->anonymousCart;
109
}
110
120
public
function
getAnonymousCartSignInMode
()
121
{
122
return
$this->anonymousCartSignInMode;
123
}
124
133
public
function
getAnonymousId
()
134
{
135
return
$this->anonymousId;
136
}
137
147
public
function
getUpdateProductData
()
148
{
149
return
$this->updateProductData;
150
}
151
156
public
function
withEmail
(?
string
$email)
157
{
158
$this->email = $email;
159
160
return
$this;
161
}
162
167
public
function
withPassword
(?
string
$password)
168
{
169
$this->password = $password;
170
171
return
$this;
172
}
173
178
public
function
withAnonymousCartId
(?
string
$anonymousCartId)
179
{
180
$this->anonymousCartId = $anonymousCartId;
181
182
return
$this;
183
}
184
189
public
function
withAnonymousCart
(?
CartResourceIdentifier
$anonymousCart)
190
{
191
$this->anonymousCart = $anonymousCart;
192
193
return
$this;
194
}
195
200
public
function
withAnonymousCartSignInMode
(?
string
$anonymousCartSignInMode)
201
{
202
$this->anonymousCartSignInMode = $anonymousCartSignInMode;
203
204
return
$this;
205
}
206
211
public
function
withAnonymousId
(?
string
$anonymousId)
212
{
213
$this->anonymousId = $anonymousId;
214
215
return
$this;
216
}
217
222
public
function
withUpdateProductData
(?
bool
$updateProductData)
223
{
224
$this->updateProductData = $updateProductData;
225
226
return
$this;
227
}
228
233
public
function
withAnonymousCartBuilder
(?
CartResourceIdentifierBuilder
$anonymousCart)
234
{
235
$this->anonymousCart = $anonymousCart;
236
237
return
$this;
238
}
239
240
public
function
build
():
CustomerSignin
241
{
242
return
new
CustomerSigninModel
(
243
$this->email,
244
$this->password,
245
$this->anonymousCartId,
246
$this->anonymousCart instanceof
CartResourceIdentifierBuilder
? $this->anonymousCart->
build
() : $this->anonymousCart,
247
$this->anonymousCartSignInMode,
248
$this->anonymousId,
249
$this->updateProductData
250
);
251
}
252
253
public
static
function
of
():
CustomerSigninBuilder
254
{
255
return
new
self
();
256
}
257
}
Commercetools\Api\Models\Cart\CartResourceIdentifierBuilder
Definition
CartResourceIdentifierBuilder.php:24
Commercetools\Api\Models\Cart\CartResourceIdentifierBuilder\build
build()
Definition
CartResourceIdentifierBuilder.php:82
Commercetools\Api\Models\Customer\CustomerSigninBuilder
Definition
CustomerSigninBuilder.php:24
Commercetools\Api\Models\Customer\CustomerSigninBuilder\withAnonymousCart
withAnonymousCart(?CartResourceIdentifier $anonymousCart)
Definition
CustomerSigninBuilder.php:189
Commercetools\Api\Models\Customer\CustomerSigninBuilder\getAnonymousId
getAnonymousId()
Definition
CustomerSigninBuilder.php:133
Commercetools\Api\Models\Customer\CustomerSigninBuilder\getEmail
getEmail()
Definition
CustomerSigninBuilder.php:73
Commercetools\Api\Models\Customer\CustomerSigninBuilder\withAnonymousCartBuilder
withAnonymousCartBuilder(?CartResourceIdentifierBuilder $anonymousCart)
Definition
CustomerSigninBuilder.php:233
Commercetools\Api\Models\Customer\CustomerSigninBuilder\getPassword
getPassword()
Definition
CustomerSigninBuilder.php:84
Commercetools\Api\Models\Customer\CustomerSigninBuilder\getAnonymousCartId
getAnonymousCartId()
Definition
CustomerSigninBuilder.php:95
Commercetools\Api\Models\Customer\CustomerSigninBuilder\withPassword
withPassword(?string $password)
Definition
CustomerSigninBuilder.php:167
Commercetools\Api\Models\Customer\CustomerSigninBuilder\getAnonymousCart
getAnonymousCart()
Definition
CustomerSigninBuilder.php:106
Commercetools\Api\Models\Customer\CustomerSigninBuilder\withAnonymousCartId
withAnonymousCartId(?string $anonymousCartId)
Definition
CustomerSigninBuilder.php:178
Commercetools\Api\Models\Customer\CustomerSigninBuilder\withEmail
withEmail(?string $email)
Definition
CustomerSigninBuilder.php:156
Commercetools\Api\Models\Customer\CustomerSigninBuilder\withUpdateProductData
withUpdateProductData(?bool $updateProductData)
Definition
CustomerSigninBuilder.php:222
Commercetools\Api\Models\Customer\CustomerSigninBuilder\of
static of()
Definition
CustomerSigninBuilder.php:253
Commercetools\Api\Models\Customer\CustomerSigninBuilder\getUpdateProductData
getUpdateProductData()
Definition
CustomerSigninBuilder.php:147
Commercetools\Api\Models\Customer\CustomerSigninBuilder\withAnonymousCartSignInMode
withAnonymousCartSignInMode(?string $anonymousCartSignInMode)
Definition
CustomerSigninBuilder.php:200
Commercetools\Api\Models\Customer\CustomerSigninBuilder\getAnonymousCartSignInMode
getAnonymousCartSignInMode()
Definition
CustomerSigninBuilder.php:120
Commercetools\Api\Models\Customer\CustomerSigninBuilder\build
build()
Definition
CustomerSigninBuilder.php:240
Commercetools\Api\Models\Customer\CustomerSigninBuilder\withAnonymousId
withAnonymousId(?string $anonymousId)
Definition
CustomerSigninBuilder.php:211
Commercetools\Api\Models\Customer\CustomerSigninModel
Definition
CustomerSigninModel.php:23
Commercetools\Base\DateTimeImmutableCollection
Definition
DateTimeImmutableCollection.php:21
Commercetools\Base\JsonObjectModel
Definition
JsonObjectModel.php:15
Commercetools\Base\MapperFactory
Definition
MapperFactory.php:16
Commercetools\Api\Models\Cart\CartResourceIdentifier
Definition
CartResourceIdentifier.php:16
Commercetools\Api\Models\Customer\CustomerSignin
Definition
CustomerSignin.php:16
Commercetools\Base\Builder
Definition
Builder.php:16
Commercetools\Base\JsonObject
Definition
JsonObject.php:15
Commercetools\Api\Models\Customer
Definition
Customer.php:9
Generated by
1.9.8