상속: IDisposable, INotifyPropertyChanged
예제 #1
0
		public static IList<PotentialFile> FindFiles(NVidiaService service, string deviceToPatch)
		{
			var result = new List<PotentialFile>();
			var deviceToReplace = long.Parse(deviceToPatch, System.Globalization.NumberStyles.HexNumber);
			var patternToLocate = BitConverter.GetBytes(deviceToReplace);
			if (service.ImagePath != null)
			{
				foreach (var file in Directory.GetFiles(service.ImagePath))
				{
					var filePatcher = new FilePatcher(file, patternToLocate);
					if (filePatcher.Count != 2)
					{
						continue;
					}
					var potentialFile = new PotentialFile
					{
						Patcher = filePatcher,
					};
					result.Add(potentialFile);
				}
			}


			return result;
		}
예제 #2
0
        public static IList <PotentialFile> FindFiles(NVidiaService service, string deviceToPatch)
        {
            var result          = new List <PotentialFile>();
            var deviceToReplace = long.Parse(deviceToPatch, System.Globalization.NumberStyles.HexNumber);
            var patternToLocate = BitConverter.GetBytes(deviceToReplace);

            if (service.ImagePath != null)
            {
                foreach (var file in Directory.GetFiles(service.ImagePath))
                {
                    var filePatcher = new FilePatcher(file, patternToLocate);
                    if (filePatcher.Count != 2)
                    {
                        continue;
                    }
                    var potentialFile = new PotentialFile
                    {
                        Patcher = filePatcher,
                    };
                    result.Add(potentialFile);
                }
            }


            return(result);
        }