File recognition

All operating systems have the ability to recognize file types. Without a recognition scheme in place, the system would be incapable of distinction, and a picture and text file would be treated the same.

In 2017 this is a feature we take for granted. Yet the way a recognition scheme works behind the scenes have serious implications. In our times users deal with gigabytes where they once handled megabytes. Tens of files have turned into tens of thousands of files. The time the operating system spends on recognizing a file can, when dealing with terabytes and millions of files, be the difference between using and not using a system.

What is file recognition? It is to store data in a specific way so content becomes predictable and easy to categorize.

Schemes of the past

There have been many schemes over the years to simplify file type detection. In my view Microsoft came up with the fastest and most intuitive: namely to give files a last name.

In this scheme a file with text always ends with “.txt” (example: my letter.txt), which provides a superficial but important predictability of content. So the last-name scheme hints of what the file contains and as such, a program doesn’t have to open a file and validate the content until you ask for it.

This last name (“.txt” in our example here) is simply refered to as a file extension.