We want to create a list of car dealer shops.
We have a CarService that is responsible for the saving and retrieving of car data. The CarDealerService is responsible for the saving and retrieving of the Dealer information.
- Create the Dealer class.
- Look at the Brand class. Why would you choose an Enum (https://www.w3schools.com/java/java_enums.asp) here?
- Implement the methods in the CarDealerServiceImpl.
- Use the carService to retrieve data about cars.
- Make sure that all the tests are working. (And correct.)
- In the main class:
- Add two dealers:
- Van Mossel
- Louwman
- Van Mossel has the following cars:
- 2 Tesla's
- 3 Renault's
- Louwman has the following cars:
- 2 Toyota's
- 4 Ford's
- Prove that all the other methods are working as well.
- Add two dealers:
Write down what you want to achieve if you have problems with following the flow. It may seem as a lot of information packed together, but writing/drawing will help you with forming a clear picture.
