Beispiel #1
0
        private IEnumerable <DumpUnit> FileListToDumpUnits(IEnumerable <string> files, string dir, Regex cond)
        {
            DumpUnit unit = default(DumpUnit);

            foreach (var file in files)
            {
                var match = cond.Match(file);
                if (!match.Success)
                {
                    continue;
                }

                unit.start = Convert.ToUInt32(match.Groups[1].Value, 16);
                unit.end   = Convert.ToUInt32(match.Groups[2].Value, 16);
                unit.path  = Path.Combine(dir, file);
                yield return(unit);
            }
        }
Beispiel #2
0
 public DumpHandle(DumpUnit unit)
 {
     this.Unit     = unit;
     this.Provider = new FileByteProvider(unit.path);
 }