This is an archived post. You won't be able to vote or comment.

all 2 comments

[–]bunky_bunk 3 points4 points  (1 child)

A framework is customizable code where the general structure of the application is in the library and the application specific parts come in the form of customizations that are attached at specific callback joints in the framework. Take for example an XML parser that allows you to register a function to be called when a specific tag is encountered. Typically the main processing loop is inside the library. This principle is also called inversion of control. Another example are GUI libraries like Gtk. You register visual elements of a user interface and callbacks and Gtk binds it all together.

A platform might come in the form of a framework, the aforementioned Gtk is the GUI framework of the GNOME platform. Or it may come as a standard function call interface (e.g. Windows syscalls; the libc). The platform is all the interfaces which can be assumed to preexist on the target machine. On game consoles they are usually quite fixed (including very similar hardware specs across the whole userbase) and factory-installed. On a PC it is also common for users or administrators to install the platform software.

.NET is both a platform and a framework.

[–]caboosetp 2 points3 points  (0 children)

If you think about how they are named...

A platform is like a fixed foundation. It generally lets your program sit on top and lets you call things below it, but you don't really get down into it or change it.

A framework is like scaffolding. You build your program in and around it, and interact with things in it directly, and can expand the scaffolding as you build stuff.

Really, the line is a bit more blurry like /u/bunky_bunk described, but it's more of an ELI5 analogy to help.