예제 #1
0
 public static void Set <T>(Tx tx, byte[] key, T dto)
 {
     using (var mem = new MemoryStream()) {
         Serializer.Serialize(mem, dto);
         tx.Put(key, mem.ToArray());
     }
 }
예제 #2
0
 public static void SetEmpty(Tx tx, byte[] key)
 {
     tx.Put(key, EmptyBuffer);
 }
예제 #3
0
 public static void SetValue(Tx tx, byte[] key, long value)
 {
     tx.Put(key, Slice.FromInt64(value).GetBytes());
 }