public IEnumerable <FFile> TakeBuffer()
        {
            while (true)
            {
                FFile r = null;

                FSDBContext db = new FSDBContext(SyncPath);

                r = db.FFiles
                    .FirstOrDefault(r1 => true &&
                                    (r1.Status == FFileStatus.New || r1.Status == FFileStatus.Existing) &&
                                    r1.Path.Contains(db.Fullpath) &&
                                    r1.ProcessingStatus == null
                                    );
                if (r == null)
                {
                    yield break;
                }
                else
                {
                    r.ProcessingStatus = ProcessingStatus.Processing;
                    db.SaveChanges();
                    yield return(r);
                }
            }
        }
 public FSDBLogic(string path)
 {
     if (string.IsNullOrEmpty(path))
     {
         throw new Exception("");
     }
     db = new FSDBContext(path);
 }