WC_Abstract_Order_Data_Store_Interface
in
WC Order Data Store Interface
Functions that must be defined by order store classes.
Tags
Table of Contents
- delete_items() : mixed
- Remove all line items (products, coupons, shipping, taxes) from the order.
- get_payment_token_ids() : array<string|int, mixed>
- Get token ids for an order.
- read_items() : array<string|int, mixed>
- Read order items of a specific type from the database for this order.
- update_payment_token_ids() : mixed
- Update token ids for an order.
Methods
delete_items()
Remove all line items (products, coupons, shipping, taxes) from the order.
public
delete_items(WC_Order $order[, string $type = null ]) : mixed
Parameters
- $order : WC_Order
-
Order object.
- $type : string = null
-
Order item type. Default null.
Return values
mixed —get_payment_token_ids()
Get token ids for an order.
public
get_payment_token_ids(WC_Order $order) : array<string|int, mixed>
Parameters
- $order : WC_Order
-
Order object.
Return values
array<string|int, mixed> —read_items()
Read order items of a specific type from the database for this order.
public
read_items(WC_Order $order, string $type) : array<string|int, mixed>
Parameters
- $order : WC_Order
-
Order object.
- $type : string
-
Order item type.
Return values
array<string|int, mixed> —update_payment_token_ids()
Update token ids for an order.
public
update_payment_token_ids(WC_Order $order, array<string|int, mixed> $token_ids) : mixed
Parameters
- $order : WC_Order
-
Order object.
- $token_ids : array<string|int, mixed>
-
Token IDs.