@Generated(value="io.sphere.sdk.annotations.processors.generators.UpdateActionsGenerator", comments="Generated from: io.sphere.sdk.payments.Payment") public final class SetAnonymousId extends UpdateActionImpl<Payment>
anonymousId property of a Payment.
withPayment(client(), payment -> { final String anonymousId = randomString(); final Payment updatedPayment = client().executeBlocking(PaymentUpdateCommand.of(payment, SetAnonymousId.of(anonymousId))); assertThat(updatedPayment.getAnonymousId()).isEqualTo(anonymousId); return updatedPayment; });See the test code.
Payment.getAnonymousId()| Modifier and Type | Method and Description |
|---|---|
String |
getAnonymousId() |
static SetAnonymousId |
of(String anonymousId)
Creates a new update action from the given parameters.
|
static SetAnonymousId |
ofUnset()
Creates a new update action to unset the
anonymousId property. |
getActionpublic static SetAnonymousId of(@Nullable String anonymousId)
anonymousId - the anonymousId property Payment.getAnonymousId().SetAnonymousId update action.public static SetAnonymousId ofUnset()
anonymousId property.SetAnonymousId update action.