Exemplo n.º 1
0
        public static void RemoveRoom(ConversationRoom room)
        {
            var Rooms = GetRooms();

            Rooms.Remove(Rooms.First(c => c.RoomName == room.RoomName));
            using (var redisClient = RedisManager.GetClient())
            {
                redisClient.Set(RedisKey.GetKey(RedisAppKeyEnum.Alpha, RedisCategoryKeyEnum.SignalRRoom), Rooms);
            }
        }
Exemplo n.º 2
0
        public static void AddRoom(ConversationRoom room)
        {
            var Rooms = GetRooms();

            Rooms.Add(room);
            using (var redisClient = RedisManager.GetClient())
            {
                redisClient.Set(RedisKey.GetKey(RedisAppKeyEnum.Alpha, RedisCategoryKeyEnum.SignalRRoom), Rooms);
            }
        }