示例#1
0
        public MftSegmentReference FindFileNameRecordSegmentReference(string fileName)
        {
            byte[] key = FileNameRecord.GetIndexKeyBytes(fileName);
            KeyValuePair <MftSegmentReference, byte[]>?entry = FindEntry(key);

            if (entry != null)
            {
                return(entry.Value.Key);
            }
            else
            {
                return(null);
            }
        }
示例#2
0
        public KeyValuePair <MftSegmentReference, FileNameRecord>?FindFileNameRecord(string fileName)
        {
            byte[] key = FileNameRecord.GetIndexKeyBytes(fileName);
            KeyValuePair <MftSegmentReference, byte[]>?entry = FindEntry(key);

            if (entry != null)
            {
                MftSegmentReference fileReference  = entry.Value.Key;
                FileNameRecord      fileNameRecord = new FileNameRecord(entry.Value.Value, 0);
                return(new KeyValuePair <MftSegmentReference, FileNameRecord>(fileReference, fileNameRecord));
            }
            else
            {
                return(null);
            }
        }
示例#3
0
 public bool ContainsFileName(string fileName)
 {
     byte[] key = FileNameRecord.GetIndexKeyBytes(fileName);
     return(FindEntry(key) != null);
 }