Class ReturnInfoBuilder
java.lang.Object
com.commercetools.importapi.models.order_patches.ReturnInfoBuilder
- All Implemented Interfaces:
Builder<ReturnInfo>
ReturnInfoBuilder
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
ReturnInfo returnInfo = ReturnInfo.builder()
.plusItems(itemsBuilder -> itemsBuilder)
.build()
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionadd the value to the items using the builder functionbuild()
builds ReturnInfo with checking for non-null required valuesbuilds ReturnInfo without checking for non-null required valuesgetItems()
value of items}Maps toReturnInfo.returnDate
Maps toReturnInfo.returnTrackingId
items
(ReturnItemDraft... items) set values to the itemsitems
(List<ReturnItemDraft> items) set value to the itemsstatic ReturnInfoBuilder
of()
factory method for an instance of ReturnInfoBuilderstatic ReturnInfoBuilder
of
(ReturnInfo template) create builder for ReturnInfo instanceplusItems
(ReturnItemDraft... items) add values to the itemsadd the value to the items using the builder functionreturnDate
(ZonedDateTime returnDate) Maps toReturnInfo.returnDate
returnTrackingId
(String returnTrackingId) Maps toReturnInfo.returnTrackingId
set the value to the items using the builder functionset the value to the items using the builder function
-
Constructor Details
-
ReturnInfoBuilder
public ReturnInfoBuilder()
-
-
Method Details
-
items
set values to the items- Parameters:
items
- value to be set- Returns:
- Builder
-
items
set value to the items- Parameters:
items
- value to be set- Returns:
- Builder
-
plusItems
add values to the items- Parameters:
items
- value to be set- Returns:
- Builder
-
plusItems
add the value to the items using the builder function- Parameters:
builder
- function to build the items value- Returns:
- Builder
-
withItems
set the value to the items using the builder function- Parameters:
builder
- function to build the items value- Returns:
- Builder
-
addItems
add the value to the items using the builder function- Parameters:
builder
- function to build the items value- Returns:
- Builder
-
setItems
set the value to the items using the builder function- Parameters:
builder
- function to build the items value- Returns:
- Builder
-
returnTrackingId
Maps to
ReturnInfo.returnTrackingId
- Parameters:
returnTrackingId
- value to be set- Returns:
- Builder
-
returnDate
Maps to
ReturnInfo.returnDate
- Parameters:
returnDate
- value to be set- Returns:
- Builder
-
getItems
value of items}- Returns:
- items
-
getReturnTrackingId
Maps to
ReturnInfo.returnTrackingId
- Returns:
- returnTrackingId
-
getReturnDate
Maps to
ReturnInfo.returnDate
- Returns:
- returnDate
-
build
builds ReturnInfo with checking for non-null required values- Specified by:
build
in interfaceBuilder<ReturnInfo>
- Returns:
- ReturnInfo
-
buildUnchecked
builds ReturnInfo without checking for non-null required values- Returns:
- ReturnInfo
-
of
factory method for an instance of ReturnInfoBuilder- Returns:
- builder
-
of
create builder for ReturnInfo instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-