Package com.commercetools.api.models.me
Interface MyCustomerSetDefaultShippingAddressAction
- All Superinterfaces:
MyCustomerUpdateAction,ResourceUpdateAction<MyCustomerUpdateAction>
Sets the default shipping address from addresses. If the address is not currently a shipping address, it is added to shippingAddressIds. Either addressId or addressKey is required.
Example to create an instance using the builder pattern
MyCustomerSetDefaultShippingAddressAction myCustomerSetDefaultShippingAddressAction = MyCustomerSetDefaultShippingAddressAction.builder()
.build()
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringdiscriminator value for MyCustomerSetDefaultShippingAddressAction -
Method Summary
Modifier and TypeMethodDescriptionbuilder()builder factory method for MyCustomerSetDefaultShippingAddressActioncreate builder for MyCustomerSetDefaultShippingAddressAction instancecopyDeep()factory method to create a deep copy of MyCustomerSetDefaultShippingAddressActionidof the Address to become the default shipping address.keyof the Address to become the default shipping address.of()factory methodof(MyCustomerSetDefaultShippingAddressAction template) factory method to create a shallow copy MyCustomerSetDefaultShippingAddressActionvoidsetAddressId(String addressId) idof the Address to become the default shipping address.voidsetAddressKey(String addressKey) keyof the Address to become the default shipping address.static com.fasterxml.jackson.core.type.TypeReference<MyCustomerSetDefaultShippingAddressAction>gives a TypeReference for usage with Jackson DataBinddefault <T> TwithMyCustomerSetDefaultShippingAddressAction(Function<MyCustomerSetDefaultShippingAddressAction, T> helper) accessor map functionMethods inherited from interface com.commercetools.api.models.me.MyCustomerUpdateAction
getAction, withMyCustomerUpdateActionMethods inherited from interface com.commercetools.api.models.ResourceUpdateAction
get
-
Field Details
-
SET_DEFAULT_SHIPPING_ADDRESS
discriminator value for MyCustomerSetDefaultShippingAddressAction- See Also:
-
-
Method Details
-
getAddressId
String getAddressId()idof the Address to become the default shipping address.- Returns:
- addressId
-
getAddressKey
String getAddressKey()keyof the Address to become the default shipping address.- Returns:
- addressKey
-
setAddressId
idof the Address to become the default shipping address.- Parameters:
addressId- value to be set
-
setAddressKey
keyof the Address to become the default shipping address.- Parameters:
addressKey- value to be set
-
of
factory method- Returns:
- instance of MyCustomerSetDefaultShippingAddressAction
-
of
static MyCustomerSetDefaultShippingAddressAction of(MyCustomerSetDefaultShippingAddressAction template) factory method to create a shallow copy MyCustomerSetDefaultShippingAddressAction- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
MyCustomerSetDefaultShippingAddressAction copyDeep()- Specified by:
copyDeepin interfaceMyCustomerUpdateAction
-
deepCopy
@Nullable static MyCustomerSetDefaultShippingAddressAction deepCopy(@Nullable MyCustomerSetDefaultShippingAddressAction template) factory method to create a deep copy of MyCustomerSetDefaultShippingAddressAction- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for MyCustomerSetDefaultShippingAddressAction- Returns:
- builder
-
builder
static MyCustomerSetDefaultShippingAddressActionBuilder builder(MyCustomerSetDefaultShippingAddressAction template) create builder for MyCustomerSetDefaultShippingAddressAction instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withMyCustomerSetDefaultShippingAddressAction
default <T> T withMyCustomerSetDefaultShippingAddressAction(Function<MyCustomerSetDefaultShippingAddressAction, T> helper) accessor map function- Type Parameters:
T- mapped type- Parameters:
helper- function to map the object- Returns:
- mapped value
-
typeReference
static com.fasterxml.jackson.core.type.TypeReference<MyCustomerSetDefaultShippingAddressAction> typeReference()gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-