.Net and Football. What?

you are new to programming or want to learn .net framework from rare basics, then this is the place for you. You are probably wondering about the title of this post ".Net and Football". Well, it seems funny, but I have chosen this because if you know one thing better, it's easy to know something else which is similar to the things you know.
Football is very popular game worldwide, and almost every child and teenager like it. OK, so let's begin playing football and learning .Net Framework.

To start playing football, you need to learn the rules and the ecosystem about it. Just as we need a football court to play football, we need .Net Framework to run our .Net program.

.Net Framework - The Football Court

A football court consist of a well spread grass, two goal posts, boundaries with some fixed length and width. Similarly, a .Net framework consists of a base container over which the following components are laid out:

Common Language Runtime (CLR)
The .Net Framework Class Library
Common Language Specification and Common Type System

Common Language Runtime (CLR) - The Referee

We can visualize CLR as a referee of the match, who controls everything as the match progresses. He manages everything from goal count, goal by whom, penalties, giving or denying permission to play. Similarly, CLR Compiles application into the runtime, compile the IL code into native code, execute the code.

The CLR has the following features:

Manages memory
Memory allocation
Memory de-Allocation
Thread execution support
Code execution
Code safety verification
Convert MSIL to Native Code
Code Security (granted permission to execute code. Code level, Folder level, Machine level)

The .Net framework class library - Things of play

Just like we require different things to play football for e.g. Hand gloves, football shoes, goal post stand etc., the .Net framework class library provides us different in-built functionalities to build a program.
.Net base class library consist of predefined reusable classes, interface and types. It also provides core programming features such as Reflection, File IO, XML, Collections etc. All the core classes interface and types can be used with any .NET Framework programming languages

CLS and CTS - Different teams, different cultures, one rule.

The two team in football might be from different countries speaking different language. So how can they communicate while playing football. Well, there is a common language that is flowing between these two teams which is the language of rules. Both team know the rules of the game very well. They know if one does a penalty, the other team have an advantage of penalty shoot-out. Similarly, there is a common set of language rules defined for all the language supported by .Net framework and that language set is called Common Language Specification (CLS).
In .NET, every Data Type is internally represented by a class or structure. All the classes and structures related to Data Types are collectively known as CTS.

.Net Assembly - The Player

The players themselves can be considered as Assemblies. A player is a unit of executing the play. Similarly, an assembly is a unit of execution of a program. Many assemblies work together to execute a program. However, unlike football, assembly can be one or many.

Assembly Metadata - Player's info (statistics, ranking etc.)

It is interesting to know about a player's carrier statistics, history, ranking etc. So these are the details that is associated with the player. Similarly, there are some additional details that are associated with the assembly itself, we call this information as metadata. This information includes description of the Assembly , datatypes and members with their declarations and implementations, references to other types and members, security permissions etc.

Copyright @ 2017