#include "ABCCommon.h" #include "ABCOrderTaker.h" #include "ABCOrderProcessor.h" #include "ABCBook.h" #include "ABCMagazine.h" void GenerateOrders(); int main(int argc, char* argv[]) { unsigned int uiAnswer; do { uiAnswer = 0; cout << endl; cout << "**************************************************" << endl; cout << endl; cout << "1 - Start Server to process incoming orders" << endl; cout << "2 - Start Client to generate predefined orders" << endl; cout << "0 - Quit" << endl; cout << endl; cout << "**************************************************" << endl; cout << endl << "Which Test should be run? : "; cin >> uiAnswer; switch (uiAnswer) { case 1 : { ABCOrderProcessor OrderProcessor; // Call ProcessIncomingOrders which will loop forever processing // orders from clients. OrderProcessor.ProcessIncomingOrders(); break; } case 2 : { // Send some orders GenerateOrders(); break; } case 0 : { return 0; } } // switch }while (uiAnswer != 0);//while return 0; } void GenerateOrders() { abc_status sStatus; // // Create an Order Taker. // ABCOrderTaker OrderTaker; // // Create a sample book order and populate it with the ISBN 49, Price and Title // ABCBook Book; Book.AddOrder( 49, 12345, "Everything to the Internet", "Michael Capellas"); // // Send this book order to the server for processing. // // note: This will be txn #1 // cout << endl << "Transaction # 1" <