org.broadleafcommerce.core.inventory.domain
Interface SkuAvailability

All Superinterfaces:
Serializable
All Known Implementing Classes:
SkuAvailabilityImpl

public interface SkuAvailability
extends Serializable

Implementations of this interface are used to hold data about SKU availability.

You should implement this class if you want to make significant changes to how the class is persisted. If you just want to add additional fields then you should extend SkuAvailabilityImpl.

Author:
bpolster
See Also:
SkuAvailabilityImpl}

Method Summary
 Date getAvailabilityDate()
          Returns the data the SKU will be available.
 AvailabilityStatusType getAvailabilityStatus()
          Returns an implementation specific availability status.
 Integer getAvailableQuantity()
          Returns the getQuantityOnHand() - getReserveQuantity().
 Long getId()
          Returns the id of this SkuAvailability
 Long getLocationId()
          Returns the USPSLocation id of this skuAvailability.
 Integer getQuantityOnHand()
          Returns the number of this items that are currently in stock and available for sell.
 Integer getReserveQuantity()
          Returns the reserve quantity.
 Long getSkuId()
          Returns the id of this SKU associated with SkuAvailability record
 void setAvailabilityDate(Date availabilityDate)
          Sets the date the SKU will be available.
 void setAvailabilityStatus(AvailabilityStatusType status)
          Sets the availability status.
 void setId(Long id)
          Sets the id of this SkuAvailability record
 void setLocationId(Long id)
          Sets the USPSLocation id of this skuAvailability.
 void setQuantityOnHand(Integer quantityOnHand)
          Sets the quantity on hand.
 void setReserveQuantity(Integer reserveQuantity)
          Sets the reserve quantity.
 void setSkuId(Long id)
          Sets the id of this SKU
 

Method Detail

getId

Long getId()
Returns the id of this SkuAvailability


setId

void setId(Long id)
Sets the id of this SkuAvailability record


getSkuId

Long getSkuId()
Returns the id of this SKU associated with SkuAvailability record


setSkuId

void setSkuId(Long id)
Sets the id of this SKU


getLocationId

Long getLocationId()
Returns the USPSLocation id of this skuAvailability. SKU availability records may or may not be location specific and using null locations are a common implementation model.


setLocationId

void setLocationId(Long id)
Sets the USPSLocation id of this skuAvailability. SKU availability records may or may not be location specific and using null locations are a common implementation model.


getAvailabilityStatus

AvailabilityStatusType getAvailabilityStatus()
Returns an implementation specific availability status. This property can return null.


setAvailabilityStatus

void setAvailabilityStatus(AvailabilityStatusType status)
Sets the availability status.


getAvailabilityDate

Date getAvailabilityDate()
Returns the data the SKU will be available. This property may return null which has an implementation specific meaning.


setAvailabilityDate

void setAvailabilityDate(Date availabilityDate)
Sets the date the SKU will be available. Setting to null is allowed and has an implementation specific meaning.


getQuantityOnHand

Integer getQuantityOnHand()
Returns the number of this items that are currently in stock and available for sell. Returning null has an implementation specific meaning.


setQuantityOnHand

void setQuantityOnHand(Integer quantityOnHand)
Sets the quantity on hand. Setting to null is allowed and has an implementation specific meaning.


getReserveQuantity

Integer getReserveQuantity()
Returns the reserve quantity. Nulls will be treated the same as 0. Implementations may want to manage a reserve quantity at each location so that the available quantity for purchases is the quantityOnHand - reserveQuantity.


setReserveQuantity

void setReserveQuantity(Integer reserveQuantity)
Sets the reserve quantity. Implementations may want to manage a reserve quantity at each location so that the available quantity for purchases is the quantityOnHand - reserveQuantity.


getAvailableQuantity

Integer getAvailableQuantity()
Returns the getQuantityOnHand() - getReserveQuantity(). Preferred implementation is to return null if getQuantityOnHand() is null and to treat a null in getReserveQuantity() as ZERO.



Copyright © 2012. All Rights Reserved.