Class SubscriptionBuilder

java.lang.Object
com.commercetools.api.models.subscription.SubscriptionBuilder
All Implemented Interfaces:
Builder<Subscription>

public class SubscriptionBuilder extends Object implements Builder<Subscription>
SubscriptionBuilder
Example to create an instance using the builder pattern

     Subscription subscription = Subscription.builder()
             .id("{id}")
             .version(0.3)
             .createdAt(ZonedDateTime.parse("2022-01-01T12:00:00.301Z"))
             .lastModifiedAt(ZonedDateTime.parse("2022-01-01T12:00:00.301Z"))
             .plusChanges(changesBuilder -> changesBuilder)
             .destination(destinationBuilder -> destinationBuilder)
             .plusMessages(messagesBuilder -> messagesBuilder)
             .format(formatBuilder -> formatBuilder)
             .status(SubscriptionHealthStatus.HEALTHY)
             .build()