OrderItem
in package
implements
OrderItemInterface
Class OrderItem
Tags
Interfaces, Classes and Traits
- OrderItemInterface
- Interface OrderItemInterface
Table of Contents
- $addonValues : EditableKeyValueCollection
- Order item addon collection.
- $attributes : OrderItemAttributeCollection
- Attributes of the order item.
- $checkoutInformation : string
- Checkout information.
- $discountMade : float
- Amount of discount made on this order item.
- $downloadInformation : OrderItemDownloadInformationCollection
- Download information.
- $gxCustomizerData : OrderItemGXCustomizerDataCollection
- GX customizer data.
- $name : string
- Name.
- $price : float
- Price.
- $productModel : string
- Product model.
- $quantity : float
- Quantity.
- $quantityUnitName : string
- Order item quantity unit name.
- $shippingTimeInfo : string
- Order item shipping time info text.
- $tax : float
- Tax amount.
- $taxAllowed : bool
- Tax allowed on this order item.
- __construct() : mixed
- OrderItem constructor.
- addAddonValues() : OrderItem
- Merges the existing addon values with new ones.
- deleteAddonValue() : OrderItem
- Deletes a specific addon value entry by key.
- getAddonValue() : string
- Returns the order addon key value from collection.
- getAddonValues() : EditableKeyValueCollection
- Returns the addon collection of an order item.
- getAttributes() : OrderItemAttributeCollection
- Returns the attributes of the order item.
- getCheckoutInformation() : string
- Returns the checkout information of the order item.
- getDiscountMade() : float
- Returns the amount of discount of the order item.
- getDownloadInformation() : OrderItemDownloadInformationCollection
- Returns the download information collection of the order item.
- getFinalPrice() : float
- Returns the final price of the order item.
- getGXCustomizerData() : OrderItemGXCustomizerDataCollection
- Returns the gx customizer data collection of the order item.
- getName() : string
- Returns the name of the order item.
- getPrice() : float
- Returns the price of the order item.
- getProductModel() : string
- Returns the product model of the order item.
- getQuantity() : float
- Returns the quantity of the order item.
- getQuantityUnitName() : string
- Returns the name of quantity unit of the order item.
- getShippingTimeInfo() : string
- Returns the shipping time of the order item.
- getTax() : float
- Returns the tax of the order item.
- isTaxAllowed() : bool
- Is tax of the order item allowed?
- setAddonValue() : OrderItem
- Adds/updates a key value in the addon value collection.
- setAttributes() : OrderItem
- Sets attributes of the OrderItem.
- setCheckoutInformation() : OrderItem
- Sets the checkout information.
- setDiscountMade() : OrderItem
- Sets discount of the OrderItem.
- setDownloadInformation() : OrderItem
- Sets the download information of the OrderItem.
- setGXCustomizerData() : OrderItem
- Sets the gx customizer data of the OrderItem.
- setName() : OrderItem
- Sets name of the OrderItem.
- setPrice() : OrderItem
- Sets price of the OrderItem.
- setProductModel() : OrderItem
- Sets product model of the OrderItem.
- setQuantity() : OrderItem
- Sets quantity of the OrderItem.
- setQuantityUnitName() : OrderItem
- Sets name of quantity unit of the OrderItem.
- setShippingTimeInfo() : OrderItem
- Sets shipping time of the OrderItem.
- setTax() : OrderItem
- Sets tax of the OrderItem.
- setTaxAllowed() : OrderItem
- Sets whether tax of the OrderItem is allowed or not.
Properties
$addonValues
Order item addon collection.
protected
EditableKeyValueCollection
$addonValues
$attributes
Attributes of the order item.
protected
OrderItemAttributeCollection
$attributes
$checkoutInformation
Checkout information.
protected
string
$checkoutInformation
= ''
$discountMade
Amount of discount made on this order item.
protected
float
$discountMade
= 0.0
.
$downloadInformation
Download information.
protected
OrderItemDownloadInformationCollection
$downloadInformation
$gxCustomizerData
GX customizer data.
protected
OrderItemGXCustomizerDataCollection
$gxCustomizerData
$name
Name.
protected
string
$name
= ''
$price
Price.
protected
float
$price
= 0.0
$productModel
Product model.
protected
string
$productModel
= ''
$quantity
Quantity.
protected
float
$quantity
= 0.0
$quantityUnitName
Order item quantity unit name.
protected
string
$quantityUnitName
= ''
$shippingTimeInfo
Order item shipping time info text.
protected
string
$shippingTimeInfo
= ''
$tax
Tax amount.
protected
float
$tax
= 0.0
$taxAllowed
Tax allowed on this order item.
protected
bool
$taxAllowed
= alse
Methods
__construct()
OrderItem constructor.
public
__construct(StringType $name) : mixed
Parameters
- $name : StringType
-
Order item name.
Return values
mixed —addAddonValues()
Merges the existing addon values with new ones.
public
addAddonValues(KeyValueCollection $addonValues) : OrderItem
Parameters
- $addonValues : KeyValueCollection
-
Contains the new addon values to be merged with the existing ones.
Return values
OrderItem —Same instance for method chaining.
deleteAddonValue()
Deletes a specific addon value entry by key.
public
deleteAddonValue(StringType $key) : OrderItem
Parameters
- $key : StringType
-
Addon key.
Return values
OrderItem —Same instance for method chaining.
getAddonValue()
Returns the order addon key value from collection.
public
getAddonValue(StringType $key) : string
Parameters
- $key : StringType
-
Addon key.
Return values
string —Addon value.
getAddonValues()
Returns the addon collection of an order item.
public
getAddonValues() : EditableKeyValueCollection
Return values
EditableKeyValueCollection —Addon collection.
getAttributes()
Returns the attributes of the order item.
public
getAttributes() : OrderItemAttributeCollection
Return values
OrderItemAttributeCollection —Attributes of the order item.
getCheckoutInformation()
Returns the checkout information of the order item.
public
getCheckoutInformation() : string
Return values
string —Checkout information of the order item.
getDiscountMade()
Returns the amount of discount of the order item.
public
getDiscountMade() : float
Return values
float —Amount of discount of the order item.
getDownloadInformation()
Returns the download information collection of the order item.
public
getDownloadInformation() : OrderItemDownloadInformationCollection
Return values
OrderItemDownloadInformationCollection —Download information collection of the order item.
getFinalPrice()
Returns the final price of the order item.
public
getFinalPrice() : float
Return values
float —Final price of the order item.
getGXCustomizerData()
Returns the gx customizer data collection of the order item.
public
getGXCustomizerData() : OrderItemGXCustomizerDataCollection
Return values
OrderItemGXCustomizerDataCollection —GXCustomizerData collection of the order item.
getName()
Returns the name of the order item.
public
getName() : string
Return values
string —Name of the order item.
getPrice()
Returns the price of the order item.
public
getPrice() : float
Return values
float —Price of the order item.
getProductModel()
Returns the product model of the order item.
public
getProductModel() : string
Return values
string —Product model of the order item.
getQuantity()
Returns the quantity of the order item.
public
getQuantity() : float
Return values
float —Quantity of the order item.
getQuantityUnitName()
Returns the name of quantity unit of the order item.
public
getQuantityUnitName() : string
Return values
string —Name of quantity unit of the order item.
getShippingTimeInfo()
Returns the shipping time of the order item.
public
getShippingTimeInfo() : string
Return values
string —Shipping time of the order item.
getTax()
Returns the tax of the order item.
public
getTax() : float
Return values
float —Tax of the order item.
isTaxAllowed()
Is tax of the order item allowed?
public
isTaxAllowed() : bool
Return values
bool —Is tax of the order item allowed?
setAddonValue()
Adds/updates a key value in the addon value collection.
public
setAddonValue(StringType $key, StringType $value) : OrderItem
Parameters
- $key : StringType
-
Addon key.
- $value : StringType
-
Addon value.
Return values
OrderItem —Same instance for method chaining.
setAttributes()
Sets attributes of the OrderItem.
public
setAttributes(OrderItemAttributeCollection $attributeCollection) : OrderItem
Parameters
- $attributeCollection : OrderItemAttributeCollection
-
Attributes of the OrderItem.
Return values
OrderItem —Same instance for method chaining.
setCheckoutInformation()
Sets the checkout information.
public
setCheckoutInformation(StringType $checkoutInformation) : OrderItem
Parameters
- $checkoutInformation : StringType
-
Contains the checkout info of the order item.
Return values
OrderItem —Same instance for method chaining.
setDiscountMade()
Sets discount of the OrderItem.
public
setDiscountMade(DecimalType $discount) : OrderItem
Parameters
- $discount : DecimalType
-
Discount of the OrderItem.
Return values
OrderItem —Same instance for method chaining.
setDownloadInformation()
Sets the download information of the OrderItem.
public
setDownloadInformation(OrderItemDownloadInformationCollection $downloads) : OrderItem
Parameters
- $downloads : OrderItemDownloadInformationCollection
-
Download information collection.
Return values
OrderItem —Same instance for method chaining.
setGXCustomizerData()
Sets the gx customizer data of the OrderItem.
public
setGXCustomizerData(OrderItemGXCustomizerDataCollection $gxCustomizerData) : OrderItem
Parameters
- $gxCustomizerData : OrderItemGXCustomizerDataCollection
-
GXCustomizerData collection.
Return values
OrderItem —Same instance for method chaining.
setName()
Sets name of the OrderItem.
public
setName(StringType $name) : OrderItem
Parameters
- $name : StringType
-
Name of the OrderItem.
Return values
OrderItem —Same instance for method chaining.
setPrice()
Sets price of the OrderItem.
public
setPrice(DecimalType $price) : OrderItem
Parameters
- $price : DecimalType
-
Price of the OrderItem.
Return values
OrderItem —Same instance for method chaining.
setProductModel()
Sets product model of the OrderItem.
public
setProductModel(StringType $model) : OrderItem
Parameters
- $model : StringType
-
Model of the OrderItem.
Return values
OrderItem —Same instance for method chaining.
setQuantity()
Sets quantity of the OrderItem.
public
setQuantity(DecimalType $quantity) : OrderItem
Parameters
- $quantity : DecimalType
-
Quantity of the OrderItem.
Return values
OrderItem —Same instance for method chaining.
setQuantityUnitName()
Sets name of quantity unit of the OrderItem.
public
setQuantityUnitName(StringType $name) : OrderItem
Parameters
- $name : StringType
-
Name of quantity unit of the OrderItem.
Return values
OrderItem —Same instance for method chaining.
setShippingTimeInfo()
Sets shipping time of the OrderItem.
public
setShippingTimeInfo(StringType $time) : OrderItem
Parameters
- $time : StringType
-
Shipping time of the OrderItem.
Return values
OrderItem —Same instance for method chaining.
setTax()
Sets tax of the OrderItem.
public
setTax(DecimalType $tax) : OrderItem
Parameters
- $tax : DecimalType
-
Tax of the OrderItem.
Return values
OrderItem —Same instance for method chaining.
setTaxAllowed()
Sets whether tax of the OrderItem is allowed or not.
public
setTaxAllowed(BoolType $allow) : OrderItem
Parameters
- $allow : BoolType
-
Tax allowed or not?
Return values
OrderItem —Same instance for method chaining.