Exemple #1
0
        public void TestTextAll()
        {
            var    key      = IndexKeys.TextAll();
            string expected = "{ \"$**\" : \"text\" }";

            Assert.AreEqual(expected, key.ToJson());
        }
Exemple #2
0
 public MongoIndexKeysWarpper TextAll()
 {
     if (MongoIndexKeys == null)
     {
         MongoIndexKeys = IndexKeys.TextAll();
     }
     else
     {
         MongoIndexKeys = MongoIndexKeys.TextAll();
     }
     return(this);
 }
 public void EnsureIndexExists()
 {
     collection.CreateIndex(IndexKeys.TextAll(), IndexOptions.SetName("Searchable").SetBackground(true));
 }