// Represents a collection of landmarks that represent a journey // Different instances of a Trip can be saved and loaded by the user import 'package:fast_network_navigation/structs/landmark.dart'; class Trip { final String uuid; final String cityName; final List landmarks; Trip({required this.uuid, required this.cityName, required this.landmarks}); factory Trip.fromJson(Map json) { List landmarks = []; for (var landmark in json['landmarks']) { landmarks.add(Landmark.fromJson(landmark)); } return Trip( uuid: json['uuid'], cityName: json['cityName'], landmarks: landmarks, ); } }