コード例 #1
0
 public void UpdateUser(User user)
 {
     using (var redisClient = RedisManager.GetClient())
     {
         var redisUsers = redisClient.As<User>();
         return redisUsersStore(user); ;
     }
 }
コード例 #2
0
        public long AddUser(string name, int goal)
        {

            using (var redisClient = RedisManager.GetClient())
            {
                var redisUsers = redisClient.As<User>();
                var user = new User () {
                    Name ="name", Goal = goal,
                    Id  = redisUsers.GetNextSequence() };
                redisUsers.Store(user);

                return user.Id;
            }
            
        }