EVGLineItem Class Reference
Inherits from | Declared in |
---|---|
NSObject | EVGItems.h |
A line item contains a single EVGItem
subclass and the quantity that were ordered.
Here is an example of how to initialize a single EVGLineItem
:
The item being ordered, subclass of EVGItem
.
The quantity of the item being ordered. Defaults to 1
Builds a line item which contains one or more units of a product in an order. This method only builds a data object. To use it, pass it to one of the tracking methods like [EVGContext addToCart:]
.
Parameters
Parameter | Description |
---|---|
item | The required EVGItem subclass being ordered |
quantity | The optional quantity, defaults to 1 |
Return Value
A line item which can be further modified.
Builds a line item which contains one or more units of a product in an order. This method only builds a data object. To use it, pass it to one of the tracking methods like [EVGContext addToCart:]
.
Parameters
Parameter | Description |
---|---|
productId | The ID of the product in this line item. This is the only required field. |
productName | The name of the product. It should be provided whenever possible. |
price | The unit price of the product. The revenue for this line item will be price x quantity. This is required when the product is being ordered but optional otherwise. |
quantity | The number of units of the product this line item represents. |
Return Value
A line item which can be further modified.