Class SubscriptionItem
java.lang.Object
com.broadleafcommerce.orderoperation.domain.subscription.SubscriptionItem
- All Implemented Interfaces:
Serializable
This represents a line item for a
Subscription.- Since:
- Order Operation Service 2.2.0, Release Train 2.3.0
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddAttribute(String name, Object value) Takes in any additional attributes passed in the request not matching any defined properties.protected booleanbooleanIf this item was the result of an add-on, then this stores the key of the add-on in the context of its parent.Why this item was archivedReturn any additional attributes passed in the request not matching any defined properties.Map holding any additional attributes passed in the request not matching any defined properties.getId()Additional details about the itemItem nameReference to the id of the item represented by this object.Type of item that this object represents.SKU of the item represented by this object.This field shows the identifier of the process or user action this subscription item originated.This field shows from which process or user action this subscription item originated.Unit price of the item (price of a single unit)Reference of the parent subscription item's backing item if this is a child subscription itemType of the parent subscription item's backing item if this is a child subscription itemintQuantity purchased.The secondary source to reference, e.g, an Order Item on an Order.The type of the secondary source to reference, e.g, an Order Item on an Order.Reference the subscription for this itemAdjustments for this subscription.Tax category of the itemComma-separated nexus codesinthashCode()booleanWhether this item is archivedbooleanWhether this item is taxablevoidsetAddOnKey(String addOnKey) If this item was the result of an add-on, then this stores the key of the add-on in the context of its parent.voidsetArchived(boolean archived) Whether this item is archivedvoidsetArchiveReason(String archiveReason) Why this item was archivedvoidsetAttributes(Map<String, Object> attributes) Map holding any additional attributes passed in the request not matching any defined properties.voidvoidsetItemDetails(Map<String, String> itemDetails) Additional details about the itemvoidsetItemName(String itemName) Item namevoidsetItemRef(String itemRef) Reference to the id of the item represented by this object.voidsetItemRefType(String itemRefType) Type of item that this object represents.voidsetItemSku(String itemSku) SKU of the item represented by this object.voidsetItemSourceRef(String itemSourceRef) This field shows the identifier of the process or user action this subscription item originated.voidsetItemSourceType(String itemSourceType) This field shows from which process or user action this subscription item originated.voidsetItemUnitPrice(BigDecimal itemUnitPrice) Unit price of the item (price of a single unit)voidsetParentItemRef(String parentItemRef) Reference of the parent subscription item's backing item if this is a child subscription itemvoidsetParentItemRefType(String parentItemRefType) Type of the parent subscription item's backing item if this is a child subscription itemvoidsetQuantity(int quantity) Quantity purchased.voidsetSecondarySourceRef(String secondarySourceRef) The secondary source to reference, e.g, an Order Item on an Order.voidsetSecondarySourceType(String secondarySourceType) The type of the secondary source to reference, e.g, an Order Item on an Order.voidsetSubscriptionId(String subscriptionId) Reference the subscription for this itemvoidsetSubscriptionItemAdjustments(List<SubscriptionItemAdjustment> subscriptionItemAdjustments) Adjustments for this subscription.voidsetTaxable(boolean taxable) Whether this item is taxablevoidsetTaxCategory(String taxCategory) Tax category of the itemvoidsetTaxNexus(String taxNexus) Comma-separated nexus codestoString()
-
Constructor Details
-
SubscriptionItem
public SubscriptionItem()
-
-
Method Details
-
addAttribute
Takes in any additional attributes passed in the request not matching any defined properties.- Parameters:
name- Name of the additional attributevalue- Value of the additional attribute
-
getAttribute
Return any additional attributes passed in the request not matching any defined properties.- Returns:
- any additional attributes passed in the request not matching any defined properties.
-
getId
-
getSubscriptionId
Reference the subscription for this item -
getItemName
Item name -
getItemRefType
Type of item that this object represents. For example, BLC_PRODUCT. -
getItemRef
Reference to the id of the item represented by this object. For example, the product id. -
getItemSku
SKU of the item represented by this object. -
getItemDetails
Additional details about the item -
getParentItemRefType
Type of the parent subscription item's backing item if this is a child subscription item -
getParentItemRef
Reference of the parent subscription item's backing item if this is a child subscription item -
getItemSourceType
This field shows from which process or user action this subscription item originated.- See Also:
-
itemSourceRefDefaultSubscriptionSourceType
-
getItemSourceRef
This field shows the identifier of the process or user action this subscription item originated.- See Also:
-
itemSourceType
-
getSecondarySourceType
The type of the secondary source to reference, e.g, an Order Item on an Order. Optional.- See Also:
-
secondarySourceRefDefaultSubscriptionSourceType
-
getSecondarySourceRef
The secondary source to reference, e.g, an Order Item on an Order. Optional.- See Also:
-
secondarySourceType
-
getAddOnKey
If this item was the result of an add-on, then this stores the key of the add-on in the context of its parent. This is important when editing a subscription in order to recreate the original cart item. -
getItemUnitPrice
Unit price of the item (price of a single unit) -
getQuantity
public int getQuantity()Quantity purchased. Note: this value is scaled by parent item quantity. -
isTaxable
public boolean isTaxable()Whether this item is taxable -
getTaxCategory
Tax category of the item -
getTaxNexus
Comma-separated nexus codes -
isArchived
public boolean isArchived()Whether this item is archived -
getArchiveReason
Why this item was archived -
getSubscriptionItemAdjustments
Adjustments for this subscription. This field is used for creation from an API request and is not persisted with the object -
getAttributes
Map holding any additional attributes passed in the request not matching any defined properties. -
setId
-
setSubscriptionId
Reference the subscription for this item -
setItemName
Item name -
setItemRefType
Type of item that this object represents. For example, BLC_PRODUCT. -
setItemRef
Reference to the id of the item represented by this object. For example, the product id. -
setItemSku
SKU of the item represented by this object. -
setItemDetails
Additional details about the item -
setParentItemRefType
Type of the parent subscription item's backing item if this is a child subscription item -
setParentItemRef
Reference of the parent subscription item's backing item if this is a child subscription item -
setItemSourceType
This field shows from which process or user action this subscription item originated.- See Also:
-
itemSourceRefDefaultSubscriptionSourceType
-
setItemSourceRef
This field shows the identifier of the process or user action this subscription item originated.- See Also:
-
itemSourceType
-
setSecondarySourceType
The type of the secondary source to reference, e.g, an Order Item on an Order. Optional.- See Also:
-
secondarySourceRefDefaultSubscriptionSourceType
-
setSecondarySourceRef
The secondary source to reference, e.g, an Order Item on an Order. Optional.- See Also:
-
secondarySourceType
-
setAddOnKey
If this item was the result of an add-on, then this stores the key of the add-on in the context of its parent. This is important when editing a subscription in order to recreate the original cart item. -
setItemUnitPrice
Unit price of the item (price of a single unit) -
setQuantity
public void setQuantity(int quantity) Quantity purchased. Note: this value is scaled by parent item quantity. -
setTaxable
public void setTaxable(boolean taxable) Whether this item is taxable -
setTaxCategory
Tax category of the item -
setTaxNexus
Comma-separated nexus codes -
setArchived
public void setArchived(boolean archived) Whether this item is archived -
setArchiveReason
Why this item was archived -
setSubscriptionItemAdjustments
public void setSubscriptionItemAdjustments(List<SubscriptionItemAdjustment> subscriptionItemAdjustments) Adjustments for this subscription. This field is used for creation from an API request and is not persisted with the object -
setAttributes
Map holding any additional attributes passed in the request not matching any defined properties. -
equals
-
canEqual
-
hashCode
public int hashCode() -
toString
-