OSID Logo
OSID Specifications
ordering package
Version 3.1.0
Interfaceosid.ordering.OrderItem
Implementsosid.OsidRelationship
Used Byosid.ordering.OrderItemAdminSession
osid.ordering.OrderItemList
osid.ordering.OrderItemLookupSession
Description

A OrderItem represents a collection of orders. Like all OSID objects, a OrderItem is identified by its Id and any persisted references should use the Id.

An OrderItem may have multiple unit prices for different types of currencies, such as one for payment and one for credits. Each line item cost type should be lined up with the unit price type.

Like all OsidObjects, OrderItem is managed by its OsidSessions and may not be accessed by concurrent processing threads.

MethodgetOrderId
Description

Gets the order Id for this order item.

Returnosid.id.Id the order Id
Compliancemandatory This method must be implemented.
MethodgetOrder
Description

Gets the order for this order item.

Returnosid.ordering.Order the order
ErrorsOPERATION_FAILED unable to complete request
Compliancemandatory This method must be implemented.
MethodisDerived
Description

Tests if the order item is a derived order item as opposed to one that has been explicitly selected.

Returnboolean true if this order item is derived, false otherwise
Compliancemandatory This method must be implemented.
MethodgetProductId
Description

Gets the product Id for this order item.

Returnosid.id.Id the product Id
Compliancemandatory This method must be implemented.
MethodgetProduct
Description

Gets the product for this order item.

Returnosid.ordering.Product the product
ErrorsOPERATION_FAILED unable to complete request
Compliancemandatory This method must be implemented.
MethodgetUnitPriceIds
Description

Gets the price Ids for this order item.

Returnosid.id.IdList the price Ids
Compliancemandatory This method must be implemented.
MethodgetUnitPrices
Description

Gets the prices for this order item. There may be different price types for a single order item.

Returnosid.ordering.PriceList the prices
ErrorsOPERATION_FAILED unable to complete request
Compliancemandatory This method must be implemented.
MethodgetQuantity
Description

Gets the quantity of the product.

Returncardinal the quantity of the product
Compliancemandatory This method must be implemented.
MethodgetCosts
Description

Gets the line item costs.

Returnosid.ordering.CostList the costs.
Compliancemandatory This method must be implemented.
MethodgetOrderItemRecord
Description

Gets the order item record corresponding to the given OrderItem record Type.This method is used to retrieve an object implementing the requested record. The orderItemRecordType may be the Type returned in getRecordTypes() or any of its parents in a Type hierarchy where hasRecordType(itemRecordType) is true.

Parametersosid.type.TypeorderItemRecordType the type of order item record to retrieve
Returnosid.ordering.records.OrderItemRecord the order item record
ErrorsNULL_ARGUMENT orderItemRecordType is null
OPERATION_FAILED unable to complete request
UNSUPPORTED hasRecordType(itemRecordType) is false
Compliancemandatory This method must be implemented.