@Generated(value="io.sphere.sdk.annotations.processors.generators.UpdateActionsGenerator", comments="Generated from: io.sphere.sdk.customers.Customer") public final class SetSalutation extends UpdateActionImpl<Customer>
salutation
property of a Customer
.
withCustomer(client(), customer -> { String newSalutation = "Dear Dr."; assertThat(customer.getSalutation()).isNotEqualTo(newSalutation); final Customer updatedCustomer = client().executeBlocking(CustomerUpdateCommand.of(customer, SetSalutation.of(newSalutation))); assertThat(updatedCustomer.getSalutation()).isEqualTo(newSalutation); });
See the test code.
Customer.getSalutation()
Modifier and Type | Method and Description |
---|---|
String |
getSalutation() |
static SetSalutation |
of(String salutation)
Creates a new update action from the given parameters.
|
static SetSalutation |
ofUnset()
Creates a new update action to unset the
salutation property. |
getAction
public static SetSalutation of(@Nullable String salutation)
salutation
- the salutation
property Customer.getSalutation()
.SetSalutation
update action.public static SetSalutation ofUnset()
salutation
property.SetSalutation
update action.