At present, LocationDataManager loads data from Locations.plist and stores location information in an array of strings. You will create a new structure, LocationItem, and configure LocationDataManager to use it to store a location. After that, you'll modify LocationViewController so that it can store a LocationItem instance containing the location selected by the user. You can then pass this LocationItem instance to the other view controllers in your project. Perform the following steps:
- Right-click on the Model folder inside the Location folder and select New File.
- iOS should already be selected. Choose Swift File and then click Next.
- Name this file LocationItem. Click Create.