// Option 1 (Standard): Console Text Editor. // #include #include #include "option1.h" #include "SharedLib.h" #include "TLinkedList.h" #include "TPerson.h" TLinkedList g, e; /** * @brief Callback function to process one name. static bool NameReadCallback(const int aIndex, const int aTotalCount, const std::string& aFirstName, const std::string& aLastName) { std::cout << "Reading Name " << (aIndex + 1) << " of " << aTotalCount << ": " << aFirstName << " " << aLastName << "\n"; // We only want to read 10 names (index 0 through 9) // Return false when aIndex is 9 to stop the loop after this one. return (aIndex < 9); } */ // *Inspired* by the provided NameReadCallback given above static bool onNameRead(const int aIndex, int aTotalCount, const std::string& aFirstName, const std::string& aLastName) { const ENumStatus status = (aIndex < 1500) ? EMPLOYEE : GUEST; const TPerson p(aFirstName, aLastName, status); if (status == EMPLOYEE) e.Append(p); else g.Append(p); std::cout << "[" <