bool OrderVisitor_VisitShop(OrderVisitor *order, Visitor_Shop *shop)
Represents a visit to the specified Visitor_Shop with the specified order.
void OrderVisitor_Initialize(OrderVisitor *visitor)
Initialize the specified OrderVisitor object.
void OrderVisitor_Clear(OrderVisitor *visitor)
Clear the specified OrderVisitor object, freeing up any memory that it was using. The resulting objec...
Declaration of the OrderVisitor structure and its supporting functions, OrderVisitor_Initialize(),...
bool Shop_PickupOrder(Visitor_Shop *shop, ConstStringList *items, ConstStringList *itemsToBePickedUp)
Pick up the items sold by this shop (assumes the items were ordered already). Basically,...
PlaceOrderReponse Shop_PlaceOrder(Visitor_Shop *shop, ConstStringList *itemsToOrder)
Visit the specified Visitor_Shop object to try to place an order as described in the OrderVisitor obj...
PlaceOrderReponse
Represents the possible responses from the Shop_PlaceOrder() function.
@ PlaceOrderResponse_OrderAccepted
Order was accepted.
void ConstStringList_Initialize(ConstStringList *stringList)
Initialize the given string list.
void ConstStringList_Clear(ConstStringList *stringList)
Clear the specified string list. The strings in the list are left alone, but the list itself is delet...
Represents a visitor used for ordering items from various shops. The user starts with an instance of ...
ConstStringList ItemsToOrder
Items to be ordered from any shop that sells the item.
ConstStringList ItemsReceived
List of items received from an order/pickup process.
const char * ShopNameReceivedFrom
Name of the shop that provided the item(s). Borrowed pointer.
Represents a shop in the village that can be visited.
const char * Name
Name of shop. Borrowed pointer.