Class LineItemImportDraftImpl
- All Implemented Interfaces:
CustomizableDraft<LineItemImportDraft>
,LineItemImportDraft
,io.vrap.rmf.base.client.Draft<LineItemImportDraft>
,io.vrap.rmf.base.client.ModelBase
Represents a snapshot of a Product Variant at the time it was imported with the Order. The Product Variant can be specified by providing a productId
and variant.id
, or by providing a variant.sku
.
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.vrap.rmf.base.client.ModelBase
io.vrap.rmf.base.client.ModelBase.FilteredRecursiveToStringStyle
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Custom Fields of the LineItem.The Channel used to select a Price.Inventory mode specific to the LineItem, valid for the entirequantity
of the LineItem.getKey()
User-defined unique identifier of the Line Item.getName()
Name of the Line Item.getPrice()
The Line Item price forquantity
=1
.id
of the Product the Product Variant belongs to.The number of Product Variants in the LineItem.Container for Line Item-specific addresses.getState()
States of the Line Item.The Channel used to supply Line Items.The tax rate used to calculate thetaxedPrice
of the Order.The Product Variant to use as a Line Item.int
hashCode()
void
setCustom
(CustomFieldsDraft custom) Custom Fields of the LineItem.void
setDistributionChannel
(ChannelResourceIdentifier distributionChannel) The Channel used to select a Price.void
setInventoryMode
(InventoryMode inventoryMode) Inventory mode specific to the LineItem, valid for the entirequantity
of the LineItem.void
User-defined unique identifier of the Line Item.void
setName
(LocalizedString name) Name of the Line Item.void
setPrice
(PriceDraft price) The Line Item price forquantity
=1
.void
setProductId
(String productId) id
of the Product the Product Variant belongs to.void
setQuantity
(Long quantity) The number of Product Variants in the LineItem.void
setShippingDetails
(ItemShippingDetailsDraft shippingDetails) Container for Line Item-specific addresses.void
States of the Line Item.void
States of the Line Item.void
setSupplyChannel
(ChannelResourceIdentifier supplyChannel) The Channel used to supply Line Items.void
setTaxRate
(TaxRate taxRate) The tax rate used to calculate thetaxedPrice
of the Order.void
setVariant
(ProductVariantImportDraft variant) The Product Variant to use as a Line Item.Methods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.commercetools.api.models.CustomizableDraft
unwrapCustomizableDraft
Methods inherited from interface com.commercetools.api.models.order.LineItemImportDraft
withLineItemImportDraft
Methods inherited from interface io.vrap.rmf.base.client.ModelBase
reflectionString, reflectionString
-
Constructor Details
-
LineItemImportDraftImpl
public LineItemImportDraftImpl()create empty instance
-
-
Method Details
-
getName
Name of the Line Item.
- Specified by:
getName
in interfaceLineItemImportDraft
- Returns:
- name
-
getKey
User-defined unique identifier of the Line Item.
- Specified by:
getKey
in interfaceLineItemImportDraft
- Returns:
- key
-
getVariant
The Product Variant to use as a Line Item.
- Specified by:
getVariant
in interfaceLineItemImportDraft
- Returns:
- variant
-
getProductId
id
of the Product the Product Variant belongs to.If provided, you must also set
variant.id
.- Specified by:
getProductId
in interfaceLineItemImportDraft
- Returns:
- productId
-
getQuantity
The number of Product Variants in the LineItem. Can be a negative value.
- Specified by:
getQuantity
in interfaceLineItemImportDraft
- Returns:
- quantity
-
getPrice
The Line Item price for
quantity
=1
. The amount can be negative.- Specified by:
getPrice
in interfaceLineItemImportDraft
- Returns:
- price
-
getTaxRate
The tax rate used to calculate the
taxedPrice
of the Order.- Specified by:
getTaxRate
in interfaceLineItemImportDraft
- Returns:
- taxRate
-
getDistributionChannel
The Channel used to select a Price. This Channel must have the
ProductDistribution
role.- Specified by:
getDistributionChannel
in interfaceLineItemImportDraft
- Returns:
- distributionChannel
-
getSupplyChannel
The Channel used to supply Line Items. By providing supply Channel information, you can uniquely identify Inventory entries that should be reserved. This Channel must have the
InventorySupply
role.- Specified by:
getSupplyChannel
in interfaceLineItemImportDraft
- Returns:
- supplyChannel
-
getInventoryMode
Inventory mode specific to the LineItem, valid for the entire
quantity
of the LineItem. Set only if Inventory mode should be different from theinventoryMode
specified on the OrderImportDraft.- Specified by:
getInventoryMode
in interfaceLineItemImportDraft
- Returns:
- inventoryMode
-
getShippingDetails
Container for Line Item-specific addresses.
- Specified by:
getShippingDetails
in interfaceLineItemImportDraft
- Returns:
- shippingDetails
-
getState
States of the Line Item.
- Specified by:
getState
in interfaceLineItemImportDraft
- Returns:
- state
-
getCustom
Custom Fields of the LineItem.
- Specified by:
getCustom
in interfaceCustomizableDraft<LineItemImportDraft>
- Specified by:
getCustom
in interfaceLineItemImportDraft
- Returns:
- custom
-
setName
Description copied from interface:LineItemImportDraft
Name of the Line Item.
- Specified by:
setName
in interfaceLineItemImportDraft
- Parameters:
name
- value to be set
-
setKey
Description copied from interface:LineItemImportDraft
User-defined unique identifier of the Line Item.
- Specified by:
setKey
in interfaceLineItemImportDraft
- Parameters:
key
- value to be set
-
setVariant
Description copied from interface:LineItemImportDraft
The Product Variant to use as a Line Item.
- Specified by:
setVariant
in interfaceLineItemImportDraft
- Parameters:
variant
- value to be set
-
setProductId
Description copied from interface:LineItemImportDraft
id
of the Product the Product Variant belongs to.If provided, you must also set
variant.id
.- Specified by:
setProductId
in interfaceLineItemImportDraft
- Parameters:
productId
- value to be set
-
setQuantity
Description copied from interface:LineItemImportDraft
The number of Product Variants in the LineItem. Can be a negative value.
- Specified by:
setQuantity
in interfaceLineItemImportDraft
- Parameters:
quantity
- value to be set
-
setPrice
Description copied from interface:LineItemImportDraft
The Line Item price for
quantity
=1
. The amount can be negative.- Specified by:
setPrice
in interfaceLineItemImportDraft
- Parameters:
price
- value to be set
-
setTaxRate
Description copied from interface:LineItemImportDraft
The tax rate used to calculate the
taxedPrice
of the Order.- Specified by:
setTaxRate
in interfaceLineItemImportDraft
- Parameters:
taxRate
- value to be set
-
setDistributionChannel
Description copied from interface:LineItemImportDraft
The Channel used to select a Price. This Channel must have the
ProductDistribution
role.- Specified by:
setDistributionChannel
in interfaceLineItemImportDraft
- Parameters:
distributionChannel
- value to be set
-
setSupplyChannel
Description copied from interface:LineItemImportDraft
The Channel used to supply Line Items. By providing supply Channel information, you can uniquely identify Inventory entries that should be reserved. This Channel must have the
InventorySupply
role.- Specified by:
setSupplyChannel
in interfaceLineItemImportDraft
- Parameters:
supplyChannel
- value to be set
-
setInventoryMode
Description copied from interface:LineItemImportDraft
Inventory mode specific to the LineItem, valid for the entire
quantity
of the LineItem. Set only if Inventory mode should be different from theinventoryMode
specified on the OrderImportDraft.- Specified by:
setInventoryMode
in interfaceLineItemImportDraft
- Parameters:
inventoryMode
- value to be set
-
setShippingDetails
Description copied from interface:LineItemImportDraft
Container for Line Item-specific addresses.
- Specified by:
setShippingDetails
in interfaceLineItemImportDraft
- Parameters:
shippingDetails
- value to be set
-
setState
Description copied from interface:LineItemImportDraft
States of the Line Item.
- Specified by:
setState
in interfaceLineItemImportDraft
- Parameters:
state
- values to be set
-
setState
Description copied from interface:LineItemImportDraft
States of the Line Item.
- Specified by:
setState
in interfaceLineItemImportDraft
- Parameters:
state
- values to be set
-
setCustom
Description copied from interface:LineItemImportDraft
Custom Fields of the LineItem.
- Specified by:
setCustom
in interfaceCustomizableDraft<LineItemImportDraft>
- Specified by:
setCustom
in interfaceLineItemImportDraft
- Parameters:
custom
- value to be set
-
equals
-
hashCode
public int hashCode()
-