/** * Creates a new instance of {@code TaxCategoryDraftDsl} with the values of this builder. * * @return the instance */ public TaxCategoryDraftDsl build() { return new TaxCategoryDraftDsl(description, key, name, taxRates); }
static TaxCategoryDraft of(final String name, final List<TaxRateDraft> taxRates, @Nullable final String description) { return TaxCategoryDraftDsl.of(name, taxRates, description); }
public TaxCategoryDraftDsl withKey(@Nullable final String key) { return newBuilder().key(key).build(); }
public TaxCategoryDraftDsl withDescription(@Nullable final String description) { return newBuilder().description(description).build(); }
public TaxCategoryDraftDsl withRates(final List<TaxRateDraft> taxRates) { return newBuilder().taxRates(taxRates).build(); }
/** * Creates a new object initialized with the given values. * * @param name initial value for the {@link TaxCategoryDraft#getName()} property * @param taxRates initial value for the {@link TaxCategoryDraft#getTaxRates()} property * @param description initial value for the {@link TaxCategoryDraft#getDescription()} property * @return new object initialized with the given values */ public static TaxCategoryDraftDsl of(final String name, final List<TaxRateDraft> taxRates, @Nullable final String description) { return new TaxCategoryDraftDsl(description, null, name, taxRates); }
static TaxCategoryDraft of(final String name, final List<TaxRateDraft> taxRates, @Nullable final String description) { return TaxCategoryDraftDsl.of(name, taxRates, description); }
public TaxCategoryDraftDsl withName(final String name) { return newBuilder().name(name).build(); }
/** * Creates a new object initialized with the fields of the template parameter. * * @param template the template * @return a new object initialized from the template */ public static TaxCategoryDraftDsl of(final TaxCategoryDraft template) { return new TaxCategoryDraftDsl(template.getDescription(), template.getKey(), template.getName(), template.getTaxRates()); } }
public TaxCategoryDraftDsl withTaxRates(final List<TaxRateDraft> taxRates) { return newBuilder().taxRates(taxRates).build(); }