richard
richard

Reputation: 12498

When would one use the "extension" property (inherited from "FileSystemInfo") of the "DirectoryInfo" class?

The Extension property is inherited from FileSystemInfo.

When would you use it? As far as I know, DirectoryInfo represents directories and the actions you can perform on a directory. This would never include the need for an "extension".

What's the use of this property for the DirectoryInfo class?

Upvotes: 0

Views: 223

Answers (1)

LukeH
LukeH

Reputation: 269348

Why would a DirectoryInfo object never include the need for an "extension"?

Names like foo.dir, bar.ext and foo.bar are perfectly legal for directories, in NTFS and many other filesystems.

Upvotes: 2

Related Questions