C # language:C # is an object-oriented programming language. It is a language developed for the. Net Framework Platform. The code written in C # Always runs on the. Net Framework Platform.
What is. Net Framework:It is a revolutionary new platform created by Microsoft to develop applications .. Net Framework defines the development and running environment of. Net applications, including the class libraries used in. Net applications. Similar to a Java virtual machine. Developers can write applications on various platforms and devices on this platform or environment. The. Net Framework is powerful and mainly manifested in the following aspects: (1) it provides a fully object-oriented programming environment and fully supports the transformation of object-oriented programming. Software is greatly improved in terms of reusability, scalability, maintainability, and flexibility. (2) provides compilers that support multiple programming languages so that applications can run on multiple devices. (3) provides many basic classes that developers can reuse, including threads, file input and output, database support, XML data analysis, and security control. These class libraries can be used for all. the language supported by the. Net platform. (4) powerful support for WEB applications. You can write applications that recognize the Internet and support it on the Internet, and these applications accept open standards such as XML, HTTP, and SOAP. (5) provide support for WEB Services.
The. Net Framework consists of two main components: the Common Language Runtime Library (CLR) and the unified class library set (FCL.
The. Net Framework is divided into four layers:
Level 1: Operating System (programs always run on top of the operating system, responsible for all processing)
Layer 2: CLR (Common Language Runtime public Language Runtime Library), responsible for memory management, thread management, remote processing, and other core services. It contains two parts: CLS and CTS. (Common Language Runtime Library extraction. net application, compile the processor code of the cost machine, and perform security checks. It can automatically process object la S and manage object references. When objects are no longer used, release them. This eliminates memory leaks and other common programming errors .)
Layer 3: FCL (. Net Framework Class Library is the. Net Framework Class Library), which includes the following three layers:
Level 1: Basic Framework
Level 2: ADO. Net and XML classes
Level 3: WebForms, WebService, and WinForms.
(It is a collection of comprehensive and object-oriented reusable types, including libraries composed of classes, interfaces, and value types. It is the basis for establishing. Net Framework applications, components, and spaces .)
Layer 4: Language layer, such as VC ++. Net, C #, VB. NET, and VJ ++.
. Net Framework Working principle:First, the source code is compiled into the MSIL (Microsoft Intermediate Language) code, and then compiled into the machine code by the real-time Compiler (JIT. C # And. Net Support code written in other languages, compiled into MSIL through their respective compilers, and then compiled into the corresponding operating system dedicated code through the JIT compiler. In this way, code hosting is implemented to improve program running efficiency.
The specific functions of each module are as follows:
1) WinForm class: Provides the Windows form application programming and development class.
2) WebForm class: Provides webpage design and development classes.
3) WebService class: Provides the class for designing Web services, which can be used to construct network service applications.
4) ADO. NET class: class that provides interactive operations with databases
5) XML class: Provides XML data operation and conversion
6) Basic Framework: provides basic input/output, string operations, and security management
7) CLS (general language specification): defines a set of basic language functions that must be followed by all languages to ensure language interoperability in the. Net Framework.
(8) CTS (common type system): describes how to declare, use, and manage classes, structures, enumerations, interfaces, and Other types when a program is running.