public void Dispose() { if (_fdb != null) { _fdb.Dispose(); _fdb = null; } }
async private Task <string[]> DatasetNames() { try { SQLiteFDB fdb = new SQLiteFDB(); if (!await fdb.Open(_filename)) { _errMsg = fdb.LastErrorMessage; return(null); } string[] ds = await fdb.DatasetNames(); string[] dsMod = new string[ds.Length]; int i = 0; foreach (string dsname in ds) { var isImageDatasetResult = await fdb.IsImageDataset(dsname); string imageSpace = isImageDatasetResult.imageSpace; if (isImageDatasetResult.isImageDataset) { dsMod[i++] = "#" + dsname; } else { dsMod[i++] = dsname; } } if (ds == null) { _errMsg = fdb.LastErrorMessage; } fdb.Dispose(); return(dsMod); } catch (Exception ex) { _errMsg = ex.Message; return(null); } }