Class DeliveryChangeValueBuilder
- All Implemented Interfaces:
Builder<DeliveryChangeValue>
Example to create an instance using the builder pattern
DeliveryChangeValue deliveryChangeValue = DeliveryChangeValue.builder()
.plusItems(itemsBuilder -> itemsBuilder)
.address(addressBuilder -> addressBuilder)
.plusParcels(parcelsBuilder -> parcelsBuilder)
.build()
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddItems
(Function<DeliveryItemBuilder, DeliveryItem> builder) Line Items or Custom Line Items shipped in the Delivery.addParcels
(Function<ParcelBuilder, Parcel> builder) Parcels included in the Delivery.Address to which the parcels are delivered.address
(Function<AddressBuilder, AddressBuilder> builder) Address to which the parcels are delivered.build()
builds DeliveryChangeValue with checking for non-null required valuesbuilds DeliveryChangeValue without checking for non-null required valuesAddress to which the parcels are delivered.getItems()
Line Items or Custom Line Items shipped in the Delivery.Parcels included in the Delivery.items
(DeliveryItem... items) Line Items or Custom Line Items shipped in the Delivery.items
(List<DeliveryItem> items) Line Items or Custom Line Items shipped in the Delivery.static DeliveryChangeValueBuilder
of()
factory method for an instance of DeliveryChangeValueBuilderstatic DeliveryChangeValueBuilder
of
(DeliveryChangeValue template) create builder for DeliveryChangeValue instanceParcels included in the Delivery.Parcels included in the Delivery.plusItems
(DeliveryItem... items) Line Items or Custom Line Items shipped in the Delivery.Line Items or Custom Line Items shipped in the Delivery.plusParcels
(Parcel... parcels) Parcels included in the Delivery.plusParcels
(Function<ParcelBuilder, ParcelBuilder> builder) Parcels included in the Delivery.setItems
(Function<DeliveryItemBuilder, DeliveryItem> builder) Line Items or Custom Line Items shipped in the Delivery.setParcels
(Function<ParcelBuilder, Parcel> builder) Parcels included in the Delivery.withAddress
(Function<AddressBuilder, Address> builder) Address to which the parcels are delivered.Line Items or Custom Line Items shipped in the Delivery.withParcels
(Function<ParcelBuilder, ParcelBuilder> builder) Parcels included in the Delivery.
-
Constructor Details
-
DeliveryChangeValueBuilder
public DeliveryChangeValueBuilder()
-
-
Method Details
-
items
Line Items or Custom Line Items shipped in the Delivery.
- Parameters:
items
- value to be set- Returns:
- Builder
-
items
Line Items or Custom Line Items shipped in the Delivery.
- Parameters:
items
- value to be set- Returns:
- Builder
-
plusItems
Line Items or Custom Line Items shipped in the Delivery.
- Parameters:
items
- value to be set- Returns:
- Builder
-
plusItems
public DeliveryChangeValueBuilder plusItems(Function<DeliveryItemBuilder, DeliveryItemBuilder> builder) Line Items or Custom Line Items shipped in the Delivery.
- Parameters:
builder
- function to build the items value- Returns:
- Builder
-
withItems
public DeliveryChangeValueBuilder withItems(Function<DeliveryItemBuilder, DeliveryItemBuilder> builder) Line Items or Custom Line Items shipped in the Delivery.
- Parameters:
builder
- function to build the items value- Returns:
- Builder
-
addItems
Line Items or Custom Line Items shipped in the Delivery.
- Parameters:
builder
- function to build the items value- Returns:
- Builder
-
setItems
Line Items or Custom Line Items shipped in the Delivery.
- Parameters:
builder
- function to build the items value- Returns:
- Builder
-
address
Address to which the parcels are delivered.
- Parameters:
builder
- function to build the address value- Returns:
- Builder
-
withAddress
Address to which the parcels are delivered.
- Parameters:
builder
- function to build the address value- Returns:
- Builder
-
address
Address to which the parcels are delivered.
- Parameters:
address
- value to be set- Returns:
- Builder
-
parcels
Parcels included in the Delivery.
- Parameters:
parcels
- value to be set- Returns:
- Builder
-
parcels
Parcels included in the Delivery.
- Parameters:
parcels
- value to be set- Returns:
- Builder
-
plusParcels
Parcels included in the Delivery.
- Parameters:
parcels
- value to be set- Returns:
- Builder
-
plusParcels
Parcels included in the Delivery.
- Parameters:
builder
- function to build the parcels value- Returns:
- Builder
-
withParcels
Parcels included in the Delivery.
- Parameters:
builder
- function to build the parcels value- Returns:
- Builder
-
addParcels
Parcels included in the Delivery.
- Parameters:
builder
- function to build the parcels value- Returns:
- Builder
-
setParcels
Parcels included in the Delivery.
- Parameters:
builder
- function to build the parcels value- Returns:
- Builder
-
getItems
Line Items or Custom Line Items shipped in the Delivery.
- Returns:
- items
-
getAddress
Address to which the parcels are delivered.
- Returns:
- address
-
getParcels
Parcels included in the Delivery.
- Returns:
- parcels
-
build
builds DeliveryChangeValue with checking for non-null required values- Specified by:
build
in interfaceBuilder<DeliveryChangeValue>
- Returns:
- DeliveryChangeValue
-
buildUnchecked
builds DeliveryChangeValue without checking for non-null required values- Returns:
- DeliveryChangeValue
-
of
factory method for an instance of DeliveryChangeValueBuilder- Returns:
- builder
-
of
create builder for DeliveryChangeValue instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-