コード例 #1
0
 public void Dispose()
 {
     StaticDocumentDatabase.DisposeDatabaseEngine();
     DB.Dispose();
     DB = null;
     currentCollection = null;
 }
コード例 #2
0
 public DocumentStoreDatabaseService(string dbPath, string collectionName)
 {
     DB = StaticDocumentDatabase.GetDatabase(dbPath.ToLower() + ".db");
     currentCollection = DB.GetCollection <IDbRecord>(collectionName);
     currentCollection.EnsureIndex(t => t.Id);
     currentCollection.EnsureIndex(t => t.TextSearchKey);
 }
コード例 #3
0
 public void CreateDb(string dbPath)
 {
     DB = StaticDocumentDatabase.GetDatabase(dbPath);
 }