public SfbFileSystemEntry(string path, bool hidden, SfbFileSystemEntryType type)
        {
            path = SfbFileSystem.GetNormalizedPath(path);
            this.path = path;
            this.type = type;
            this.hidden = hidden;

            name = SfbFileSystem.GetFileName(path);
            if (type == SfbFileSystemEntryType.File) {
                extension = SfbFileSystem.GetExtension(path);
            }

            ReadLastWriteTime();
        }
Example #2
0
        public static SfbEntryType Convert(this SfbFileSystemEntryType fde)
        {
            switch (fde)
            {
            case SfbFileSystemEntryType.File:
                return(SfbEntryType.File);

            case SfbFileSystemEntryType.Folder:
            case SfbFileSystemEntryType.LogicalDrive:
            case SfbFileSystemEntryType.Root:
                return(SfbEntryType.Folder);
            }

            return(SfbEntryType.File);
        }
        public SfbFileSystemEntry(string path, bool hidden, SfbFileSystemEntryType type)
        {
            path        = SfbFileSystem.GetNormalizedPath(path);
            this.path   = path;
            this.type   = type;
            this.hidden = hidden;

            name = SfbFileSystem.GetFileName(path);
            if (type == SfbFileSystemEntryType.File)
            {
                extension = SfbFileSystem.GetExtension(path);
            }

            ReadLastWriteTime();
        }
 private SfbSavedLocationEntry(SfbSavedLocationType locationType, DateTime savedDate, string path, bool hidden, SfbFileSystemEntryType type)
     : base(path, hidden, type)
 {
     this.locationType = locationType;
     this.savedDate = savedDate;
 }
 public SfbSavedLocationEntry(SfbSavedLocationType locationType, string path, bool hidden, SfbFileSystemEntryType type)
     : base(path, hidden, type)
 {
     this.locationType = locationType;
     savedDate = DateTime.Now;
 }
Example #6
0
 public SfbSavedLocationEntry(SfbSavedLocationType locationType, string path, bool hidden, SfbFileSystemEntryType type) : base(path, hidden, type)
 {
     this.locationType = locationType;
     savedDate         = DateTime.Now;
 }
Example #7
0
 private SfbSavedLocationEntry(SfbSavedLocationType locationType, DateTime savedDate, string path, bool hidden, SfbFileSystemEntryType type) : base(path, hidden, type)
 {
     this.locationType = locationType;
     this.savedDate    = savedDate;
 }