Class VariantDetail
java.lang.Object
com.broadleafcommerce.catalog.domain.product.commerce.VariantDetail
- All Implemented Interfaces:
Serializable
A version of
Variant
tailored toward the needs of a commerce-facing product details page.- Author:
- Nathan Moore (nathandmoore)
- See Also:
-
Constructor Summary
ConstructorDescriptionVariantDetail
(Variant variant, PriceInfo priceInfo, String vendorRef, List<ProductTag> advancedTags) -
Method Summary
Modifier and TypeMethodDescriptionprotected boolean
boolean
The product tags associated with this variant.<T> T
getAttribute
(String name) com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextState
javax.money.MonetaryAmount
getCost()
javax.money.MonetaryAmount
getId()
getName()
com.broadleafcommerce.data.tracking.core.filtering.domain.ChangeContainer
Summary of thepricing information
related to the variant.javax.money.MonetaryAmount
getSku()
getUpc()
Soft reference to the vendor associated with this catalog.int
hashCode()
boolean
isActive()
boolean
boolean
isOnline()
boolean
isOnSale()
void
setActiveEndDate
(Instant activeEndDate) void
setActiveStartDate
(Instant activeStartDate) void
setAdvancedTags
(List<ProductTag> advancedTags) The product tags associated with this variant.void
setAttributes
(Map<String, Attribute> attributes) void
setContextState
(com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextState contextState) void
setCost
(javax.money.MonetaryAmount cost) void
setDefaultPrice
(javax.money.MonetaryAmount defaultPrice) void
setDescription
(String description) void
setDimension
(Dimensions dimension) void
setDiscountable
(boolean discountable) void
setExternalId
(String externalId) void
setFulfillmentFlatRates
(Map<String, FulfillmentFlatRate> fulfillmentFlatRates) void
void
setInventoryCheckStrategy
(String inventoryCheckStrategy) void
setInventoryReservationStrategy
(String inventoryReservationStrategy) void
setMaximumThreshold
(Integer maximumThreshold) void
setMinimumThreshold
(Integer minimumThreshold) void
void
setOnline
(boolean online) void
setOptionValues
(Map<String, String> optionValues) void
setOverrideChangeContainer
(com.broadleafcommerce.data.tracking.core.filtering.domain.ChangeContainer overrideChangeContainer) void
setPriceInfo
(PriceInfo priceInfo) Summary of thepricing information
related to the variant.void
setProductId
(String productId) void
setReviewsSummary
(ReviewsSummary reviewsSummary) void
setSalePrice
(javax.money.MonetaryAmount salePrice) void
void
setTaxCode
(String taxCode) void
void
setVariant
(Variant variant) void
setVendorRef
(String vendorRef) Soft reference to the vendor associated with this catalog.void
toString()
-
Constructor Details
-
VariantDetail
public VariantDetail(Variant variant, PriceInfo priceInfo, String vendorRef, List<ProductTag> advancedTags) -
VariantDetail
public VariantDetail()
-
-
Method Details
-
getVariant
-
getPriceInfo
Summary of thepricing information
related to the variant.- Returns:
- Summary of the
pricing information
related to the variant
-
getVendorRef
Soft reference to the vendor associated with this catalog. This value can be null, in which case, no vendor is associated.- Returns:
- Soft reference to the vendor associated with this catalog.
-
getAdvancedTags
The product tags associated with this variant. Must be hydrated.- Returns:
- The tags associated with this variant
-
setVariant
-
setPriceInfo
Summary of thepricing information
related to the variant.- Parameters:
priceInfo
- Summary of thepricing information
related to the variant
-
setVendorRef
Soft reference to the vendor associated with this catalog. This value can be null, in which case, no vendor is associated.- Parameters:
vendorRef
- Soft reference to the vendor associated with this catalog.
-
setAdvancedTags
The product tags associated with this variant. Must be hydrated.- Parameters:
productTags
- The tags associated with this variant
-
equals
-
canEqual
-
hashCode
public int hashCode() -
toString
-
getAttribute
-
isActive
public boolean isActive() -
isOnSale
public boolean isOnSale() -
getId
-
getSku
-
getUpc
-
getExternalId
-
getName
-
getDescription
-
getActiveStartDate
-
getActiveEndDate
-
getDefaultPrice
public javax.money.MonetaryAmount getDefaultPrice() -
getSalePrice
public javax.money.MonetaryAmount getSalePrice() -
getCost
public javax.money.MonetaryAmount getCost() -
getDimension
-
getWeight
-
isOnline
public boolean isOnline() -
isDiscountable
public boolean isDiscountable() -
getProductId
-
getOptionValues
-
getInventoryCheckStrategy
-
getInventoryReservationStrategy
-
getReviewsSummary
-
getMinimumThreshold
-
getMaximumThreshold
-
getFulfillmentFlatRates
-
getAttributes
-
getContextState
public com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextState getContextState() -
getTaxCode
-
getOverrideChangeContainer
public com.broadleafcommerce.data.tracking.core.filtering.domain.ChangeContainer getOverrideChangeContainer() -
setId
-
setSku
-
setUpc
-
setExternalId
-
setName
-
setDescription
-
setActiveStartDate
-
setActiveEndDate
-
setDefaultPrice
public void setDefaultPrice(javax.money.MonetaryAmount defaultPrice) -
setSalePrice
public void setSalePrice(javax.money.MonetaryAmount salePrice) -
setCost
public void setCost(javax.money.MonetaryAmount cost) -
setDimension
-
setWeight
-
setOnline
public void setOnline(boolean online) -
setDiscountable
public void setDiscountable(boolean discountable) -
setProductId
-
setOptionValues
-
setInventoryCheckStrategy
-
setInventoryReservationStrategy
-
setReviewsSummary
-
setMinimumThreshold
-
setMaximumThreshold
-
setFulfillmentFlatRates
-
setAttributes
-
setContextState
public void setContextState(com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextState contextState) -
setTaxCode
-
setOverrideChangeContainer
public void setOverrideChangeContainer(com.broadleafcommerce.data.tracking.core.filtering.domain.ChangeContainer overrideChangeContainer)
-