001 002package com.commercetools.api.models.me; 003 004import java.util.*; 005 006import javax.annotation.Nullable; 007 008import io.vrap.rmf.base.client.Builder; 009import io.vrap.rmf.base.client.utils.Generated; 010 011/** 012 * MyCustomerAddBillingAddressIdActionBuilder 013 * <hr> 014 * Example to create an instance using the builder pattern 015 * <div class=code-example> 016 * <pre><code class='java'> 017 * MyCustomerAddBillingAddressIdAction myCustomerAddBillingAddressIdAction = MyCustomerAddBillingAddressIdAction.builder() 018 * .build() 019 * </code></pre> 020 * </div> 021 */ 022@Generated(value = "io.vrap.rmf.codegen.rendering.CoreCodeGenerator", comments = "https://github.com/commercetools/rmf-codegen") 023public class MyCustomerAddBillingAddressIdActionBuilder implements Builder<MyCustomerAddBillingAddressIdAction> { 024 025 @Nullable 026 private String addressId; 027 028 @Nullable 029 private String addressKey; 030 031 /** 032 * <p><code>id</code> of the Address to become a billing address.</p> 033 * @param addressId value to be set 034 * @return Builder 035 */ 036 037 public MyCustomerAddBillingAddressIdActionBuilder addressId(@Nullable final String addressId) { 038 this.addressId = addressId; 039 return this; 040 } 041 042 /** 043 * <p><code>key</code> of the Address to become a billing address.</p> 044 * @param addressKey value to be set 045 * @return Builder 046 */ 047 048 public MyCustomerAddBillingAddressIdActionBuilder addressKey(@Nullable final String addressKey) { 049 this.addressKey = addressKey; 050 return this; 051 } 052 053 /** 054 * <p><code>id</code> of the Address to become a billing address.</p> 055 * @return addressId 056 */ 057 058 @Nullable 059 public String getAddressId() { 060 return this.addressId; 061 } 062 063 /** 064 * <p><code>key</code> of the Address to become a billing address.</p> 065 * @return addressKey 066 */ 067 068 @Nullable 069 public String getAddressKey() { 070 return this.addressKey; 071 } 072 073 /** 074 * builds MyCustomerAddBillingAddressIdAction with checking for non-null required values 075 * @return MyCustomerAddBillingAddressIdAction 076 */ 077 public MyCustomerAddBillingAddressIdAction build() { 078 return new MyCustomerAddBillingAddressIdActionImpl(addressId, addressKey); 079 } 080 081 /** 082 * builds MyCustomerAddBillingAddressIdAction without checking for non-null required values 083 * @return MyCustomerAddBillingAddressIdAction 084 */ 085 public MyCustomerAddBillingAddressIdAction buildUnchecked() { 086 return new MyCustomerAddBillingAddressIdActionImpl(addressId, addressKey); 087 } 088 089 /** 090 * factory method for an instance of MyCustomerAddBillingAddressIdActionBuilder 091 * @return builder 092 */ 093 public static MyCustomerAddBillingAddressIdActionBuilder of() { 094 return new MyCustomerAddBillingAddressIdActionBuilder(); 095 } 096 097 /** 098 * create builder for MyCustomerAddBillingAddressIdAction instance 099 * @param template instance with prefilled values for the builder 100 * @return builder 101 */ 102 public static MyCustomerAddBillingAddressIdActionBuilder of(final MyCustomerAddBillingAddressIdAction template) { 103 MyCustomerAddBillingAddressIdActionBuilder builder = new MyCustomerAddBillingAddressIdActionBuilder(); 104 builder.addressId = template.getAddressId(); 105 builder.addressKey = template.getAddressKey(); 106 return builder; 107 } 108 109}