コード例 #1
0
 @Override
 public RedisClient restore(
     String key, long millis, String serialized, Handler<AsyncResult<String>> handler) {
   send(
       RESTORE,
       RedisCommandUtils.toPayload(key, millis, RedisEncoding.decode(serialized)),
       String.class,
       true,
       handler);
   return this;
 }
コード例 #2
0
 @Override
 public RedisClient dump(String key, Handler<AsyncResult<String>> handler) {
   send(
       DUMP,
       RedisCommandUtils.toPayload(key),
       String.class,
       true,
       dump -> {
         if (dump.failed()) {
           handler.handle(dump);
         } else {
           handler.handle(Future.succeededFuture(RedisEncoding.encode(dump.result())));
         }
       });
   return this;
 }