ZenMagick 0.9.8


org.zenmagick.store.model.order.ZMOrderItem
\store\model\order\ZMOrderItem.php at line 34

Class ZMOrderItem

ZMObject
└─ZMOrderItem

public class ZMOrderItem
extends ZMObject

A single order item

Author:
DerManoMann
Version:
$Id: ZMOrderItem.php 2694 2009-12-03 22:32:18Z dermanomann $

Fields inherited from org.zenmagick.core.ZMObject
properties_
Constructor Summary

ZMOrderItem()

Create new instance.

Method Summary
void

addAttribute(ZMAttribute attribute)

Add an item attribute.

array

getAttributes()

Get the item attributes.

float

getCalculatedPrice()

Get the calculated price.

int

getId()

Get the order item id.

string

getModel()

Get the model.

string

getName()

Get the item name.

ZMProduct

getProduct()

Get the product this item is associated to.

int

getProductId()

Get the order item product id.

int

getQty()

Get the quantity.

float

getTaxRate()

Get the tax rate.

boolean

hasAttributes()

Checks if the item has associated attributes.

void

setAttributes(array attributes)

Set item attributes.

void

setCalculatedPrice(float price)

Set the calculated price.

void

setId(int id)

Set the order item id.

void

setModel(string model)

Set the model.

void

setName(string name)

Set the item name.

void

setProductId(int productId)

Set the order item product id.

void

setQty(int qty)

Set the quantity.

void

setTaxRate(float taxRate)

Set the tax rate.

Methods inherited from org.zenmagick.core.ZMObject
attachMethod, get, getAttachedMethods, getPropertyNames, set, singleton

Constructor Detail

\store\model\order\ZMOrderItem.php at line 47

ZMOrderItem

public ZMOrderItem()

Create new instance.


Method Detail

\store\model\order\ZMOrderItem.php at line 194

addAttribute

public void addAttribute(ZMAttribute attribute)

Add an item attribute.

Parameters:
attribute - A ZMAttribute.

\store\model\order\ZMOrderItem.php at line 138

getAttributes

public array getAttributes()

Get the item attributes.

Returns:
A list of ZMAttribute instances.

\store\model\order\ZMOrderItem.php at line 124

getCalculatedPrice

public float getCalculatedPrice()

Get the calculated price.

Returns:
The calculated price.

\store\model\order\ZMOrderItem.php at line 66

getId

public int getId()

Get the order item id.

Returns:
The order item id.

\store\model\order\ZMOrderItem.php at line 103

getModel

public string getModel()

Get the model.

Returns:
The item model.

\store\model\order\ZMOrderItem.php at line 96

getName

public string getName()

Get the item name.

Returns:
The item name.

\store\model\order\ZMOrderItem.php at line 80

getProduct

public ZMProduct getProduct()

Get the product this item is associated to.

Returns:
The product.

\store\model\order\ZMOrderItem.php at line 73

getProductId

public int getProductId()

Get the order item product id.

Returns:
The order item product id.

\store\model\order\ZMOrderItem.php at line 89

getQty

public int getQty()

Get the quantity.

Returns:
The quantity for this item.

\store\model\order\ZMOrderItem.php at line 110

getTaxRate

public float getTaxRate()

Get the tax rate.

Returns:
The tax rate.

\store\model\order\ZMOrderItem.php at line 131

hasAttributes

public boolean hasAttributes()

Checks if the item has associated attributes.

Returns:
true if attributes exist, false if not.

\store\model\order\ZMOrderItem.php at line 201

setAttributes

public void setAttributes(array attributes)

Set item attributes.

Parameters:
attributes - A list of ZMAttribute instances.

\store\model\order\ZMOrderItem.php at line 187

setCalculatedPrice

public void setCalculatedPrice(float price)

Set the calculated price.

Parameters:
price - The calculated price.

\store\model\order\ZMOrderItem.php at line 145

setId

public void setId(int id)

Set the order item id.

Parameters:
id - The order item id.

\store\model\order\ZMOrderItem.php at line 173

setModel

public void setModel(string model)

Set the model.

Parameters:
model - The item model.

\store\model\order\ZMOrderItem.php at line 166

setName

public void setName(string name)

Set the item name.

Parameters:
name - The item name.

\store\model\order\ZMOrderItem.php at line 152

setProductId

public void setProductId(int productId)

Set the order item product id.

Parameters:
productId - The order item product id.

\store\model\order\ZMOrderItem.php at line 159

setQty

public void setQty(int qty)

Set the quantity.

Parameters:
qty - The quantity for this item.

\store\model\order\ZMOrderItem.php at line 180

setTaxRate

public void setTaxRate(float taxRate)

Set the tax rate.

Parameters:
taxRate - The tax rate.

ZenMagick 0.9.8