Ejemplo n.º 1
0
 private void CopyAtHomeBinaries(DriveStorageDetails storageDetails)
 {
     string copyAtHomeBinariesFrom = Server.MapPath("/binaries");
     string copyAtHomeBinariesTo = string.Format("{0}{1}", storageDetails.RootPath, "client");
     if (!Directory.Exists(copyAtHomeBinariesTo))
         Directory.CreateDirectory(copyAtHomeBinariesTo);
     logger.Info("Starting to copy AtHome binaries");
     foreach (var file in Directory.EnumerateFiles(copyAtHomeBinariesFrom))
     {
         String fileName = System.IO.Path.GetFileName(file);
         logger.Info("Copying file {0}", fileName);
         String destFile = System.IO.Path.Combine(copyAtHomeBinariesTo, fileName);
         if (File.Exists(destFile)) continue;
         System.IO.File.Copy(file, destFile, true);
     }
     logger.Info("Done copying AtHome Binaries");
 }
Ejemplo n.º 2
0
 public FoldingClient(DriveStorageDetails driveStorageToUse,IAtHomeClientDataRepository repositoryToStoreData)
 {
     this.StorageToUse = driveStorageToUse;
     _clientDataRepo = repositoryToStoreData;
     this.Identity = _clientDataRepo.LoadClientInformation();
 }