Into the pit. NET has been more than two years, since in the Microsoft. NET system mix, the. NET system also needs to understand, of course, these knowledge is also available to check the information can be found, here is mainly for their own study of the collation, and the recent study some of the smell behind closed doors, now want to write out and share with you, If the understanding is biased, welcome to the Garden friends correct me!
The. Net framework has undergone many version changes, but its framework has not changed much, including the common language runtime (CLR), the base Class library, and the. NET Framework class library, the common Language specification, and the supported languages;
Common language Runtime (CLR)
The CLR is the underlying content of the. Net framework, too. NET program can be seen as a proxy for managing code at execution time, providing core services such as memory management, thread management, code execution, garbage collection (GC), and remoting, as well as enforcing strict type safety and other forms of code accuracy that improve security and reliability.
The source code written in C # or any other language generates IL code-managed (Il also called managed code) through the compiler, and finally a managed module, one or more managed module assemblies (assembly) to the CLR, but the CLR cannot directly interact with the operating system (OS). The JIT engine is also required to "translate" into binary code that the computer can recognize and give to the operating system for execution.
Yes, the CLR mentioned here has to mention managed and unmanaged code:
Managed code is code that is executed by the CLR (not directly by the operating system), managed. Managed code applications can obtain common language runtime services, such as automatic garbage collection, runtime type checking, and security support. These services help provide platform-and language-independent, unified managed-code application behavior. Using managed code in a managed execution environment and its compilation avoids many of the typical programming errors that lead to security black holes and unstable programs. Similarly, many unreliable designs are automatically enhanced with security, such as type safety checks, memory management, and the release of invalid objects. Programmers can devote more attention to the application logic design of the program and can reduce the amount of code written. This means shorter development times and more robust programs.
Unmanaged code is code that is executed directly outside of the common language runtime environment by the operating system unmanaged. Unmanaged code must provide its own garbage collection, type checking, security support, and other services, unlike managed code, which obtains these services from the common language runtime.
Base class libraries and the. Net Framework
The base class libraries (NET standard library) contain a wide range of common features that support the underlying operations, covering such areas as collection operations, threading support, code generation, input and output (IO), mapping, and security. In addition,. NET core is also a base Class library implementation, of course, it has its own unique implementation, and unlike the. NET Framework, it is supported across platforms, and detailed learning will be shared in subsequent blogs.
The. Net framework is the implementation of the base Class library under the Windows operating system, including the class Library: Database Access (ADO. NET, XML support, directory services (LDAP, etc.), regular expressions, and message support, and also implement many of the application development techniques that our developers typically use: ASP. and advanced programming technologies such as NET technology, Winfroms Technology, and WPF technology.
Common Language Specification
Unfortunately, I have no knowledge of the Common Language Specification (CLS), and I can only talk about it.
. NET supports many languages, C #, VB, and so on, each language must carry its own characteristics, but everyone can be compiled on the CLR run, and can be interoperable with other languages, because all languages adhere to the Cls;.net framework defines the CLS as a set of rules, All. NET language should follow this rule in order to create applications that interoperate with other languages, but be aware that in order for the languages to interoperate, you can use only the feature objects listed in the CLS, which are collectively known as CLS-compliant features. Further down the details of the implementation will not know, this is also listed in the future study plan it.
Summarize
This blog is written here, the content is mostly the contents of the garden, but also hope to help to want to enter the pit. Net of friends.
Category: First-order look-back tags:. Net
. NET