CLI & CLR

This article gives a basic introduction to the CLI, the components of the CLI and CLR and the features of the CLR.

Common Language Infrastructure (CLI)

CLI is a specification developed by Microsoft that describes the executable code and runtime environment. In simple terms this allows us to use various high level languages on various machines without rewriting the code.

CLI is divided into four main components.

Common type system (CTS)

CTS defines some basic data types and every language that is designed for use with .NET framework should be able to match its data types to these defined basic data types. So when various languages are designed following CTS, they will be able to communicate with each other and this is nothing but cross-language interoperability or communication.

Common Language Specification (CLS)

CLS is a set of specifications that must be met by every language to be considered as .NET compliant. It is a subset of CTS types and a set of rules. Example: Elimination of pointers and multiple inheritance.

Metadata

Metadata gives information about all the classes and the class members defined in the assembly. You will learn later what an assembly means.

Virtual Execution System (VES)

VES loads and runs the programs that are compatible with the CLI using metadata.

To make it clear, CLI is a set of specifications for a virtual operating system that is nothing but a Common Language Runtime (CLR).

Common Language Runtime (CLR)

Is the virtual machine component in the .NET Framework better known as the runtime and is responsible for executing .NET programs. 

The following are the features of the CLR:

  • Memory management

  • Exception handling

  • Code access security

  • Thread execution

  • Debugging

  • Verification & Compilation

All the features of the CLR will be explained in the later parts of the tutorial.

Up Next
    Ebook Download
    View all
    Learn
    View all