Beispiel #1
0
        public void Put()
        {
            Database.Put (null, "key1", "value1");
            Database.Put (null, "key2", "value2");
            Database.Put (null, "key3", "value3");

            var options = new WriteOptions () {
                Sync = true
            };
            Database.Put (options, "key4", "value4");
        }
Beispiel #2
0
 /// <summary>
 /// Set the database entry for "key" to "value".
 /// </summary>
 public void Put(String key, String value, WriteOptions options)
 {
     this.Put(Encoding.UTF8.GetBytes(key), Encoding.UTF8.GetBytes(value), options);
 }
Beispiel #3
0
 /// <summary>
 /// Set the database entry for "key" to "value".
 /// Note: consider setting new WriteOptions{ Sync = true }.
 /// </summary>
 public void Put(string key, string value, WriteOptions options)
 {
     this.Put(_encoding.GetBytes(key), _encoding.GetBytes(value), options);
 }
Beispiel #4
0
 /// <summary>
 /// Remove the database entry (if any) for "key".
 /// It is not an error if "key" did not exist in the database.
 /// </summary>
 public void Delete(String key, WriteOptions options)
 {
     this.Delete(Encoding.UTF8.GetBytes(key), options);
 }
Beispiel #5
0
 /// <summary>
 /// Remove the database entry (if any) for "key".
 /// It is not an error if "key" did not exist in the database.
 /// Note: consider setting new WriteOptions{ Sync = true }.
 /// </summary>
 public void Delete(string key, WriteOptions options)
 {
     this.Delete(_encoding.GetBytes(key), options);
 }