Back to course home
0% completed
Vote For New Content
why are we including order variable in Customer class??
asra.naseem517
Nov 27, 2024
public abstract class Customer { private ShoppingCart cart; private Order order; public ShoppingCart getShoppingCart(); public bool addItemToCart(Item item); public bool removeItemFromCart(Item item); } public class Guest extends Customer { public bool registerAccount(); }
In the requirement it is mentioned that guest should not have access to place an order , but here guest extends the functionality of Customer which has Order in it , can you explain why do we have order in Customer class?
0
0
Comments
Comments