Milestone 3 Milestone 3 implements and tests the Workstation and…
Question Answered step-by-step Milestone 3 Milestone 3 implements and tests the Workstation and… Milestone 3Milestone 3 implements and tests the Workstation and LineManager modules.The LineManager module first configures the assembly line and then moves CustomerOrders along it (from start to finish). The LineManager object configures the Workstation objects identified by the user, and moves orders along the line one step at a time. A Workstation is a Station that the LineManager has activated on the user’s request. At each step, every Workstation fills one item in a Customer Order, if possible. The manager moves orders from station to station. Once an order has reached the end of the line, it is either complete or incomplete. An order is incomplete if one or more stations had an insufficient number of items in stock to cover that order’s requests.Workstation ModuleThe Workstation module consists of three double-ended queues of CustomerOrder and the Workstation class. The queues (global variables) hold the orders at either end of the assembly line:g_pending holds the orders to be placed onto the assembly line at the first station.g_completed holds the orders that have been removed from the last station and have been completely filled.g_incomplete holds the orders that have been removed from the last station and could not be filled completely.Each queue is accessible outside this module’s translation unit.The Workstation class defines the structure of an active station on the assembly line and contains all the functionality for filling customer orders with station items. Each Workstation is-a-kind-of Station. A Workstation object manages order processing for a single Item on the assembly line. Since a Workstation object represents a single location on the assembly line for filling customer orders with items, the object cannot be copied or moved. Make sure that this capability is deleted in your definition of the Workstation class.The Workstation class includes the following additional information:Instance Variablesm_orders – is a double-ended-queue with CustomerOrders entering the back and exiting the front. These are orders that have been placed on this station to receive service (or already received service).m_pNextStation – a pointer to the next Workstation on the assembly line.Member Functionsa custom 1-argument constructor — receives a reference to an unmodifiable reference to std::string and passes it to the Station base class.void fill(std::ostream& os) – this modifier fills the order at the front of the queue if there are CustomerOrders in the queue; otherwise, does nothing.bool attemptToMoveOrder() – attempts to move the order order at the front of the queue to the next station in the assembly line:if the order requires no more service at this station or cannot be filled (not enough inventory), move it to the next station; otherwise do nothingif there is no next station in the assembly line, then the order is moved into g_completed or g_incomplete queueif an order has been moved, return true; false otherwise.void setNextStation(Workstation* station) – this modifier stores the address of the referenced Workstation object in the pointer to the m_pNextStation. Parameter defaults to nullptr.Workstation* getNextStation() const – this query returns the address of next Workstationvoid display(std::ostream& os) const – this query inserts the name of the Item for which the current object is responsible into stream os following the format: ITEM_NAME –> NEXT_ITEM_NAMEif the current object is the last Workstation in the assembly line this query inserts: ITEM_NAME –> End of Line.in either case, the message is terminated with nWorkstation& operator+=(CustomerOrder&& newOrder) – moves the CustomerOrder referenced in parameter newOrder to the back of the queue.LineManager ModuleThe LineManager class manages an assembly line of active stations and contains the following information:Instance Variablesstd::vector


