Class OrderItemRepository
Class OrderItemRepository
- OrderItemRepository implements OrderItemRepositoryInterface
Package: Order\Repositories
Category: System
Located at Services/Core/Order/Repositories/OrderItemRepository.inc.php
Category: System
Located at Services/Core/Order/Repositories/OrderItemRepository.inc.php
Methods summary
public
__construct( OrderItemAttributeRepositoryFactoryInterface $orderItemAttributeRepositoryFactory, OrderItemRepositoryReaderInterface $orderItemRepositoryReader, OrderItemRepositoryWriterInterface $orderItemRepositoryWriter, OrderItemRepositoryDeleterInterface $orderItemRepositoryDeleter, AddonValueServiceInterface $addonValueService )
OrderItemRepository constructor.
public
addToOrder( IdType $orderId, OrderItemInterface $orderItem )
: integer
Adds an order item to the order item repository.
public
store( StoredOrderItemInterface $storedOrderItem )
: OrderItemRepository
Saves the order item in the repository.
public
getItemById( IdType $orderItemId )
: StoredOrderItemInterface
Returns a stored order ID by the given order item ID.
public
getItemsByOrderId( IdType $orderId )
: StoredOrderItemCollection
Returns a stored order item collection by the given order ID.
public
deleteItemById( IdType $orderItemId )
: OrderItemRepository
Deletes an order item from the repository by the given order item ID.
public
deleteItemsByOrderId( IdType $orderId )
: OrderItemRepository
Deletes order items from the repository by the given order ID.
protected
_delegateToAttributeRepositories( OrderItemInterface $orderItem, integer|null $storedOrderItemId = null )
:
Delegate to the attribute repository and save the attributes of the passed order item.
Properties summary
protected
$orderItemAttributeRepositoryFactory
: OrderItemAttributeRepositoryFactoryInterface
Order item attribute repository factory.
protected
$orderItemRepositoryReader
: OrderItemRepositoryReaderInterface
Order item repository reader.
protected
$orderItemRepositoryWriter
: OrderItemRepositoryWriterInterface
Order item repository writer.
protected
$orderItemRepositoryDeleter
: OrderItemRepositoryDeleterInterface
Order item repository deleter.