Пример #1
0
 public void Remove(WallModel wall)
 {
     if (Contains(wall))
     {
         OwnedWalls.Remove(Find(wall));
     }
 }
Пример #2
0
        public void Add(WallModel wall)
        {
            var model = DatabaseContext.Shared.WallReferences.Create();

            model.WallId = wall.WallUrl;
            model.Wall   = wall;
            OwnedWalls.Add(model);
        }
Пример #3
0
        private UserWallReference Find(WallModel model)
        {
            foreach (var wall in OwnedWalls)
            {
                if (wall.WallId == model.WallUrl)
                {
                    return(wall);
                }
            }

            return(null);
        }
Пример #4
0
 public bool Contains(WallModel wall)
 {
     return(Find(wall) != null);
 }