Exemple #1
0
 public void AddPlace(string name, params string[] tags)
 {
     var id = Places.Any() ? Places.Max(x => x.Id) + 1 : 0;
     var place = new Place(id, name, tags);
     Places.Add(place);
 }
Exemple #2
0
 public void AddPlace(Place place)
 {
     var id = Places.Any() ? Places.Max(x => x.Id) + 1 : 0;
     place.Id = id;
     Places.Add(place);
 }