SlideShare a Scribd company logo
Common language
runtime CLR
M.SandhiyaM.SC(IT)
Department of CS&IT
Nadar Saraswathi College of Arts
Science Theni
Common Language
Runtime (CLR)
• Net Framework: provides runtime environment called Common
Language Runtime (CLR).It provides an environment to run all the
Programs. The code which runs under the CLR is called as Managed
Code. Programmers need not to worry on managing the memory if
the programs are running under the CLR as it provides memory
management and thread management.
Programmatically, when our program needs memory, CLR allocates
the memory for scope and de-allocates the memory if the scope is
completed.
Language Compilers (e.g. C#, VB.Net, J#) will convert the
Code/Program to Microsoft Intermediate Language (MSIL) intern
this will be converted to Native Code by CLR. See the below Fig.
Native code
Net Framework Class
Library (FCL)
• This is also called as Base Class Library and it is common for all types of applications i.e. the way you access
the Library Classes and Methods in VB.NET will be the same in C#, and it is common for all other languages
in .NET.
The following are different types of applications that can make use of net class library.
• 1. Windows Application.
• 2. Console Application
• 3. Web Application.
• 4.XML Web Services.
• 5.Windows Services.
In short, developers just need to import the BCL in their language code and use its predefined methods and
properties to implement common and complex functions like reading and writing to file, graphic rendering,
database interaction, and XML document manipulation. Below are the few more concepts that we need to
know and understand as part of this Net framework.
Common Type System (CTS)
It describes set of data types that can be used in different Net languages in common. (i.e.) CTS ensures that
objects written in different .NET languages can interact with each other. For Communicating between
programs written in any .NET complaint language, the types have to be compatible on the basic level.
Common Type System (CTS)
 It describes set of data types that can be used in different .Net languages in common.
(i.e), CTS ensures that objects written in different
 Net languages can interact with each other.For Communicating between programs
written in any .
 NET complaint language, the types have to be compatible on the basic level.
common type system
The common type system supports two general categories of types:
• Value types:
Value types directly contain their data, and instances of value types are
either allocated on the stack or allocated inline in a structure. Value
types can be built-in (implemented by the runtime), user-defined, or
enumerations.
Reference types:
Reference types store a reference to the value's memory address, and
are allocated on the heap. Reference types can be self-describing types,
pointer types, or interface types. The type of a reference type can be
determined from values of self-describing types. Self-describing types
are further split into arrays and class types. The class types are user-
defined classes, boxed value types, and delegates.
CommonLanguageSpecification(CLS)
• It is a sub set of CTS and it specifies a set of rules that needs to
be adhered or satisfied by all language compilers targeting
CLR.
• It helps in cross language inheritance and cross language
debugging.
Common language runtime
Common language specification
Rules:
• It describes the minimal and complete set of features to produce code
that can be hosted by CLR. It ensures that products of compilers will
work properly in .NET environment.
• Sample Rules:
• 1. Representation of text strings
• 2. Internal representation of enumerations
• 3. Definition of static members and this is a subset of the CTS which
all .NET languages are expected to support.
• 4. Microsoft has defined CLS which are nothing but guidelines that
language to follow so that it can communicate with other .NET
languages in a seamless manner.
• Below mentioned the .Net Architecture stack for easy understanding.
The components of CLR includes
• Class Loader: This loads classes into the runtime.
• MSIL to native code compiler: This converts MSIL code into native code.
• Code manager: This manager the code during execution i.e provides code check,
the resources it needs during execution.
• Garbage Collector: provide automatic memory management and avoid memory
leaks.
• Security Engine: This enforces security restrictions and CAS.
• Type Checker: This enforces strict type checking.
• Thread Support: This provides multithreading support to applications.
• Exception Manager : This provides a mechanism to handle the run-time
exceptions.
• Debug Engine : Allow you to debug different type of applications.
• COM marshaler : This allows .net application to exchange data with COM
applications.
• BASE Class library : This provides the types the applications needed at runtime.
runtime
Main components of CLR
• Common Language Specification (CLS)
• Common Type System (CTS)
• Garbage Collection (GC)
• Just In – Time Compiler (JIT)
Common Language Specification (CLS):
• It is responsible for converting the different .NET programming
language syntactical rules and regulations into CLR understandable
format. Basically, it provides the Language Interoperability. Language
Interoperability means to provide the execution support to other
programming languages also in .NET framework.
Language Interoperability can be achieved in two ways :
Managed Code: The MSIL code which is managed by the CLR is known as
the Managed Code. For managed code CLR provides three .NET facilities:
CAS(Code Access Security)Exception HandlingAutomatic Memory
Management.
Common language runtime clr
Benefits of CLR:
• It improves the performance by providing a richly interact between programs at the run
time.
• Enhance portability by removing the need of recompiling a program on any operating
system that supports it.
• Security also increases as it analyzes the MSIL instructions whether they are safe or
unsafe. Also, the use of delegates in place of function pointers enhance the type safety
and security.
• Support automatic memory management with the help of Garbage Collector.
• Provides cross-language integration because CTS inside CLR provides a common
standard that activates the different languages to extend and share each other’s libraries.
• Provides support to use the components that developed in other .NET programming
languages.
• Provide language, platform, and architecture independency.
• It allows the creation of the scalable and multithreaded applications in an easier way as a
developer has no need to think about the memory management and security issues.
•
Language Interoperability can
be achieved in two ways :
Managed Code: The MSIL code which is managed by the CLR is
known as the Managed Code. For managed code CLR
provides three .
CAS(Code Access Security)Exception HandlingAutomatic Memory
Management.
Unmanaged Code: Before .NET development the programming
language like . Components & Win32 API do not generate the
MSIL code. So these are not managed by CLR rather managed
by Operating System which is called unmanaged code.
Common Type System (CTS):
• Every programming language has its own data type system, so CTS
is responsible for the understanding all the data type system of .
• NET programming languages and converting them into CLR
understandable format which will be a common format.
• There are 2 Types:
• CTS
• NET programming language
Ad

More Related Content

What's hot (20)

C# programming language
C# programming languageC# programming language
C# programming language
swarnapatil
 
Components of .NET Framework
Components of .NET FrameworkComponents of .NET Framework
Components of .NET Framework
Roshith S Pai
 
Architecture of .net framework
Architecture of .net frameworkArchitecture of .net framework
Architecture of .net framework
Then Murugeshwari
 
Introduction to c#
Introduction to c#Introduction to c#
Introduction to c#
OpenSource Technologies Pvt. Ltd.
 
C# Framework class library
C# Framework class libraryC# Framework class library
C# Framework class library
Prem Kumar Badri
 
Introduction To Dotnet
Introduction To DotnetIntroduction To Dotnet
Introduction To Dotnet
SAMIR BHOGAYTA
 
Introduction to .NET Framework
Introduction to .NET FrameworkIntroduction to .NET Framework
Introduction to .NET Framework
Raghuveer Guthikonda
 
Frame class library and namespace
Frame class library and namespaceFrame class library and namespace
Frame class library and namespace
Jaya Kumari
 
Namespaces in C#
Namespaces in C#Namespaces in C#
Namespaces in C#
yogita kachve
 
C#.NET
C#.NETC#.NET
C#.NET
gurchet
 
Java And Multithreading
Java And MultithreadingJava And Multithreading
Java And Multithreading
Shraddha
 
Java awt (abstract window toolkit)
Java awt (abstract window toolkit)Java awt (abstract window toolkit)
Java awt (abstract window toolkit)
Elizabeth alexander
 
Operators in java
Operators in javaOperators in java
Operators in java
AbhishekMondal42
 
Data types
Data typesData types
Data types
myrajendra
 
7.data types in c#
7.data types in c#7.data types in c#
7.data types in c#
Zeeshan Ahmad
 
Oops concept on c#
Oops concept on c#Oops concept on c#
Oops concept on c#
baabtra.com - No. 1 supplier of quality freshers
 
Dot net assembly
Dot net assemblyDot net assembly
Dot net assembly
Dr.Neeraj Kumar Pandey
 
Exception Handling in VB.Net
Exception Handling in VB.NetException Handling in VB.Net
Exception Handling in VB.Net
rishisingh190
 
Java threads
Java threadsJava threads
Java threads
Prabhakaran V M
 
Difference between cts and cls
Difference between cts and clsDifference between cts and cls
Difference between cts and cls
Umar Ali
 

Similar to Common language runtime clr (20)

.Net framework components by naveen kumar veligeti
.Net framework components by naveen kumar veligeti.Net framework components by naveen kumar veligeti
.Net framework components by naveen kumar veligeti
Naveen Kumar Veligeti
 
.Net overview|Introduction Of .net
.Net overview|Introduction Of .net.Net overview|Introduction Of .net
.Net overview|Introduction Of .net
pinky singh
 
election survey comapny in delhi|election survey company|election survey comp...
election survey comapny in delhi|election survey company|election survey comp...election survey comapny in delhi|election survey company|election survey comp...
election survey comapny in delhi|election survey company|election survey comp...
dnnindia
 
Dotnet1
Dotnet1Dotnet1
Dotnet1
Sudhriti Gupta
 
Chapter 1 introduction to .net
Chapter 1 introduction to .netChapter 1 introduction to .net
Chapter 1 introduction to .net
Rahul Bhoge
 
Net framework
Net frameworkNet framework
Net framework
mayankingeniar
 
Session2 (3)
Session2 (3)Session2 (3)
Session2 (3)
DrUjwala1
 
The Philosophy of .Net
The Philosophy of .NetThe Philosophy of .Net
The Philosophy of .Net
Vahid Farahmandian
 
.Net framework
.Net framework.Net framework
.Net framework
Yogendra Tamang
 
.Net Framwork Architecture And components
.Net Framwork Architecture And components.Net Framwork Architecture And components
.Net Framwork Architecture And components
syedArr
 
.Net slid
.Net slid.Net slid
.Net slid
pacatarpit
 
dotnet.pptx idurne jdie ek ieiebve ieneieie d
dotnet.pptx idurne jdie ek ieiebve ieneieie ddotnet.pptx idurne jdie ek ieiebve ieneieie d
dotnet.pptx idurne jdie ek ieiebve ieneieie d
pobeyi1413
 
.NET Framework
.NET Framework.NET Framework
.NET Framework
vijayakumari kaliannan
 
Inside.Net
Inside.NetInside.Net
Inside.Net
Ganesh Samarthyam
 
DOT NET Framework.pptxdsfdsfdsfsdfdsfdsfdsf
DOT NET Framework.pptxdsfdsfdsfsdfdsfdsfdsfDOT NET Framework.pptxdsfdsfdsfsdfdsfdsfdsf
DOT NET Framework.pptxdsfdsfdsfsdfdsfdsfdsf
zmulani8
 
1 what is microsoft .net framework
1 what is microsoft .net framework1 what is microsoft .net framework
1 what is microsoft .net framework
Islamia Univeristy Bahawalpur Bahawalnagar
 
Chapter1_Part1.pptx
Chapter1_Part1.pptxChapter1_Part1.pptx
Chapter1_Part1.pptx
RaajzKoirala
 
Inside .net framework
Inside .net frameworkInside .net framework
Inside .net framework
Faisal Aziz
 
Dot net
Dot netDot net
Dot net
public
 
1.0
1.01.0
1.0
SIVAJISADHANA
 
.Net framework components by naveen kumar veligeti
.Net framework components by naveen kumar veligeti.Net framework components by naveen kumar veligeti
.Net framework components by naveen kumar veligeti
Naveen Kumar Veligeti
 
.Net overview|Introduction Of .net
.Net overview|Introduction Of .net.Net overview|Introduction Of .net
.Net overview|Introduction Of .net
pinky singh
 
election survey comapny in delhi|election survey company|election survey comp...
election survey comapny in delhi|election survey company|election survey comp...election survey comapny in delhi|election survey company|election survey comp...
election survey comapny in delhi|election survey company|election survey comp...
dnnindia
 
Chapter 1 introduction to .net
Chapter 1 introduction to .netChapter 1 introduction to .net
Chapter 1 introduction to .net
Rahul Bhoge
 
Session2 (3)
Session2 (3)Session2 (3)
Session2 (3)
DrUjwala1
 
.Net Framwork Architecture And components
.Net Framwork Architecture And components.Net Framwork Architecture And components
.Net Framwork Architecture And components
syedArr
 
dotnet.pptx idurne jdie ek ieiebve ieneieie d
dotnet.pptx idurne jdie ek ieiebve ieneieie ddotnet.pptx idurne jdie ek ieiebve ieneieie d
dotnet.pptx idurne jdie ek ieiebve ieneieie d
pobeyi1413
 
DOT NET Framework.pptxdsfdsfdsfsdfdsfdsfdsf
DOT NET Framework.pptxdsfdsfdsfsdfdsfdsfdsfDOT NET Framework.pptxdsfdsfdsfsdfdsfdsfdsf
DOT NET Framework.pptxdsfdsfdsfsdfdsfdsfdsf
zmulani8
 
Chapter1_Part1.pptx
Chapter1_Part1.pptxChapter1_Part1.pptx
Chapter1_Part1.pptx
RaajzKoirala
 
Inside .net framework
Inside .net frameworkInside .net framework
Inside .net framework
Faisal Aziz
 
Ad

More from SanSan149 (11)

Sdma fdma-tdma-fixed tdm
Sdma fdma-tdma-fixed tdmSdma fdma-tdma-fixed tdm
Sdma fdma-tdma-fixed tdm
SanSan149
 
Histogram process spatial filtering
Histogram process spatial filteringHistogram process spatial filtering
Histogram process spatial filtering
SanSan149
 
Mobile computing vani
Mobile computing vaniMobile computing vani
Mobile computing vani
SanSan149
 
Telecommunication system gms mobile service
Telecommunication system gms mobile serviceTelecommunication system gms mobile service
Telecommunication system gms mobile service
SanSan149
 
Adaptive filters and band reject filters
Adaptive filters and band reject filtersAdaptive filters and band reject filters
Adaptive filters and band reject filters
SanSan149
 
Hema rdbms
Hema rdbmsHema rdbms
Hema rdbms
SanSan149
 
SDMA-FDMA-TDMA-fixed TDM
SDMA-FDMA-TDMA-fixed TDMSDMA-FDMA-TDMA-fixed TDM
SDMA-FDMA-TDMA-fixed TDM
SanSan149
 
joins and subqueries in big data analysis
joins and subqueries in big data analysisjoins and subqueries in big data analysis
joins and subqueries in big data analysis
SanSan149
 
Hadoop storage
Hadoop storageHadoop storage
Hadoop storage
SanSan149
 
Normalization
NormalizationNormalization
Normalization
SanSan149
 
Manageral aspects of software maintance
Manageral aspects of software maintanceManageral aspects of software maintance
Manageral aspects of software maintance
SanSan149
 
Sdma fdma-tdma-fixed tdm
Sdma fdma-tdma-fixed tdmSdma fdma-tdma-fixed tdm
Sdma fdma-tdma-fixed tdm
SanSan149
 
Histogram process spatial filtering
Histogram process spatial filteringHistogram process spatial filtering
Histogram process spatial filtering
SanSan149
 
Mobile computing vani
Mobile computing vaniMobile computing vani
Mobile computing vani
SanSan149
 
Telecommunication system gms mobile service
Telecommunication system gms mobile serviceTelecommunication system gms mobile service
Telecommunication system gms mobile service
SanSan149
 
Adaptive filters and band reject filters
Adaptive filters and band reject filtersAdaptive filters and band reject filters
Adaptive filters and band reject filters
SanSan149
 
SDMA-FDMA-TDMA-fixed TDM
SDMA-FDMA-TDMA-fixed TDMSDMA-FDMA-TDMA-fixed TDM
SDMA-FDMA-TDMA-fixed TDM
SanSan149
 
joins and subqueries in big data analysis
joins and subqueries in big data analysisjoins and subqueries in big data analysis
joins and subqueries in big data analysis
SanSan149
 
Hadoop storage
Hadoop storageHadoop storage
Hadoop storage
SanSan149
 
Normalization
NormalizationNormalization
Normalization
SanSan149
 
Manageral aspects of software maintance
Manageral aspects of software maintanceManageral aspects of software maintance
Manageral aspects of software maintance
SanSan149
 
Ad

Recently uploaded (20)

APGAR SCORE BY sweety Tamanna Mahapatra MSc Pediatric
APGAR SCORE  BY sweety Tamanna Mahapatra MSc PediatricAPGAR SCORE  BY sweety Tamanna Mahapatra MSc Pediatric
APGAR SCORE BY sweety Tamanna Mahapatra MSc Pediatric
SweetytamannaMohapat
 
Overview Well-Being and Creative Careers
Overview Well-Being and Creative CareersOverview Well-Being and Creative Careers
Overview Well-Being and Creative Careers
University of Amsterdam
 
Origin of Brahmi script: A breaking down of various theories
Origin of Brahmi script: A breaking down of various theoriesOrigin of Brahmi script: A breaking down of various theories
Origin of Brahmi script: A breaking down of various theories
PrachiSontakke5
 
How to Configure Scheduled Actions in odoo 18
How to Configure Scheduled Actions in odoo 18How to Configure Scheduled Actions in odoo 18
How to Configure Scheduled Actions in odoo 18
Celine George
 
LDMMIA Reiki Yoga S5 Daily Living Workshop
LDMMIA Reiki Yoga S5 Daily Living WorkshopLDMMIA Reiki Yoga S5 Daily Living Workshop
LDMMIA Reiki Yoga S5 Daily Living Workshop
LDM Mia eStudios
 
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Leonel Morgado
 
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
Dr. Nasir Mustafa
 
Ajanta Paintings: Study as a Source of History
Ajanta Paintings: Study as a Source of HistoryAjanta Paintings: Study as a Source of History
Ajanta Paintings: Study as a Source of History
Virag Sontakke
 
Form View Attributes in Odoo 18 - Odoo Slides
Form View Attributes in Odoo 18 - Odoo SlidesForm View Attributes in Odoo 18 - Odoo Slides
Form View Attributes in Odoo 18 - Odoo Slides
Celine George
 
puzzle Irregular Verbs- Simple Past Tense
puzzle Irregular Verbs- Simple Past Tensepuzzle Irregular Verbs- Simple Past Tense
puzzle Irregular Verbs- Simple Past Tense
OlgaLeonorTorresSnch
 
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFAMEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
Dr. Nasir Mustafa
 
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon DolabaniHistory Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
fruinkamel7m
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...
BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...
BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...
Nguyen Thanh Tu Collection
 
ANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptx
ANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptxANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptx
ANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptx
Mayuri Chavan
 
Cultivation Practice of Onion in Nepal.pptx
Cultivation Practice of Onion in Nepal.pptxCultivation Practice of Onion in Nepal.pptx
Cultivation Practice of Onion in Nepal.pptx
UmeshTimilsina1
 
How to Configure Public Holidays & Mandatory Days in Odoo 18
How to Configure Public Holidays & Mandatory Days in Odoo 18How to Configure Public Holidays & Mandatory Days in Odoo 18
How to Configure Public Holidays & Mandatory Days in Odoo 18
Celine George
 
The History of Kashmir Karkota Dynasty NEP.pptx
The History of Kashmir Karkota Dynasty NEP.pptxThe History of Kashmir Karkota Dynasty NEP.pptx
The History of Kashmir Karkota Dynasty NEP.pptx
Arya Mahila P. G. College, Banaras Hindu University, Varanasi, India.
 
Bridging the Transit Gap: Equity Drive Feeder Bus Design for Southeast Brooklyn
Bridging the Transit Gap: Equity Drive Feeder Bus Design for Southeast BrooklynBridging the Transit Gap: Equity Drive Feeder Bus Design for Southeast Brooklyn
Bridging the Transit Gap: Equity Drive Feeder Bus Design for Southeast Brooklyn
i4jd41bk
 
How to Share Accounts Between Companies in Odoo 18
How to Share Accounts Between Companies in Odoo 18How to Share Accounts Between Companies in Odoo 18
How to Share Accounts Between Companies in Odoo 18
Celine George
 
Rock Art As a Source of Ancient Indian History
Rock Art As a Source of Ancient Indian HistoryRock Art As a Source of Ancient Indian History
Rock Art As a Source of Ancient Indian History
Virag Sontakke
 
APGAR SCORE BY sweety Tamanna Mahapatra MSc Pediatric
APGAR SCORE  BY sweety Tamanna Mahapatra MSc PediatricAPGAR SCORE  BY sweety Tamanna Mahapatra MSc Pediatric
APGAR SCORE BY sweety Tamanna Mahapatra MSc Pediatric
SweetytamannaMohapat
 
Overview Well-Being and Creative Careers
Overview Well-Being and Creative CareersOverview Well-Being and Creative Careers
Overview Well-Being and Creative Careers
University of Amsterdam
 
Origin of Brahmi script: A breaking down of various theories
Origin of Brahmi script: A breaking down of various theoriesOrigin of Brahmi script: A breaking down of various theories
Origin of Brahmi script: A breaking down of various theories
PrachiSontakke5
 
How to Configure Scheduled Actions in odoo 18
How to Configure Scheduled Actions in odoo 18How to Configure Scheduled Actions in odoo 18
How to Configure Scheduled Actions in odoo 18
Celine George
 
LDMMIA Reiki Yoga S5 Daily Living Workshop
LDMMIA Reiki Yoga S5 Daily Living WorkshopLDMMIA Reiki Yoga S5 Daily Living Workshop
LDMMIA Reiki Yoga S5 Daily Living Workshop
LDM Mia eStudios
 
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Redesigning Education as a Cognitive Ecosystem: Practical Insights into Emerg...
Leonel Morgado
 
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
MCQ PHYSIOLOGY II (DR. NASIR MUSTAFA) MCQS)
Dr. Nasir Mustafa
 
Ajanta Paintings: Study as a Source of History
Ajanta Paintings: Study as a Source of HistoryAjanta Paintings: Study as a Source of History
Ajanta Paintings: Study as a Source of History
Virag Sontakke
 
Form View Attributes in Odoo 18 - Odoo Slides
Form View Attributes in Odoo 18 - Odoo SlidesForm View Attributes in Odoo 18 - Odoo Slides
Form View Attributes in Odoo 18 - Odoo Slides
Celine George
 
puzzle Irregular Verbs- Simple Past Tense
puzzle Irregular Verbs- Simple Past Tensepuzzle Irregular Verbs- Simple Past Tense
puzzle Irregular Verbs- Simple Past Tense
OlgaLeonorTorresSnch
 
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFAMEDICAL BIOLOGY MCQS  BY. DR NASIR MUSTAFA
MEDICAL BIOLOGY MCQS BY. DR NASIR MUSTAFA
Dr. Nasir Mustafa
 
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon DolabaniHistory Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
History Of The Monastery Of Mor Gabriel Philoxenos Yuhanon Dolabani
fruinkamel7m
 
BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...
BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...
BÀI TẬP BỔ TRỢ TIẾNG ANH 9 THEO ĐƠN VỊ BÀI HỌC - GLOBAL SUCCESS - CẢ NĂM (TỪ...
Nguyen Thanh Tu Collection
 
ANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptx
ANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptxANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptx
ANTI-VIRAL DRUGS unit 3 Pharmacology 3.pptx
Mayuri Chavan
 
Cultivation Practice of Onion in Nepal.pptx
Cultivation Practice of Onion in Nepal.pptxCultivation Practice of Onion in Nepal.pptx
Cultivation Practice of Onion in Nepal.pptx
UmeshTimilsina1
 
How to Configure Public Holidays & Mandatory Days in Odoo 18
How to Configure Public Holidays & Mandatory Days in Odoo 18How to Configure Public Holidays & Mandatory Days in Odoo 18
How to Configure Public Holidays & Mandatory Days in Odoo 18
Celine George
 
Bridging the Transit Gap: Equity Drive Feeder Bus Design for Southeast Brooklyn
Bridging the Transit Gap: Equity Drive Feeder Bus Design for Southeast BrooklynBridging the Transit Gap: Equity Drive Feeder Bus Design for Southeast Brooklyn
Bridging the Transit Gap: Equity Drive Feeder Bus Design for Southeast Brooklyn
i4jd41bk
 
How to Share Accounts Between Companies in Odoo 18
How to Share Accounts Between Companies in Odoo 18How to Share Accounts Between Companies in Odoo 18
How to Share Accounts Between Companies in Odoo 18
Celine George
 
Rock Art As a Source of Ancient Indian History
Rock Art As a Source of Ancient Indian HistoryRock Art As a Source of Ancient Indian History
Rock Art As a Source of Ancient Indian History
Virag Sontakke
 

Common language runtime clr

  • 1. Common language runtime CLR M.SandhiyaM.SC(IT) Department of CS&IT Nadar Saraswathi College of Arts Science Theni
  • 2. Common Language Runtime (CLR) • Net Framework: provides runtime environment called Common Language Runtime (CLR).It provides an environment to run all the Programs. The code which runs under the CLR is called as Managed Code. Programmers need not to worry on managing the memory if the programs are running under the CLR as it provides memory management and thread management. Programmatically, when our program needs memory, CLR allocates the memory for scope and de-allocates the memory if the scope is completed. Language Compilers (e.g. C#, VB.Net, J#) will convert the Code/Program to Microsoft Intermediate Language (MSIL) intern this will be converted to Native Code by CLR. See the below Fig.
  • 4. Net Framework Class Library (FCL) • This is also called as Base Class Library and it is common for all types of applications i.e. the way you access the Library Classes and Methods in VB.NET will be the same in C#, and it is common for all other languages in .NET. The following are different types of applications that can make use of net class library. • 1. Windows Application. • 2. Console Application • 3. Web Application. • 4.XML Web Services. • 5.Windows Services. In short, developers just need to import the BCL in their language code and use its predefined methods and properties to implement common and complex functions like reading and writing to file, graphic rendering, database interaction, and XML document manipulation. Below are the few more concepts that we need to know and understand as part of this Net framework. Common Type System (CTS) It describes set of data types that can be used in different Net languages in common. (i.e.) CTS ensures that objects written in different .NET languages can interact with each other. For Communicating between programs written in any .NET complaint language, the types have to be compatible on the basic level.
  • 5. Common Type System (CTS)  It describes set of data types that can be used in different .Net languages in common. (i.e), CTS ensures that objects written in different  Net languages can interact with each other.For Communicating between programs written in any .  NET complaint language, the types have to be compatible on the basic level.
  • 6. common type system The common type system supports two general categories of types: • Value types: Value types directly contain their data, and instances of value types are either allocated on the stack or allocated inline in a structure. Value types can be built-in (implemented by the runtime), user-defined, or enumerations. Reference types: Reference types store a reference to the value's memory address, and are allocated on the heap. Reference types can be self-describing types, pointer types, or interface types. The type of a reference type can be determined from values of self-describing types. Self-describing types are further split into arrays and class types. The class types are user- defined classes, boxed value types, and delegates.
  • 7. CommonLanguageSpecification(CLS) • It is a sub set of CTS and it specifies a set of rules that needs to be adhered or satisfied by all language compilers targeting CLR. • It helps in cross language inheritance and cross language debugging.
  • 9. Common language specification Rules: • It describes the minimal and complete set of features to produce code that can be hosted by CLR. It ensures that products of compilers will work properly in .NET environment. • Sample Rules: • 1. Representation of text strings • 2. Internal representation of enumerations • 3. Definition of static members and this is a subset of the CTS which all .NET languages are expected to support. • 4. Microsoft has defined CLS which are nothing but guidelines that language to follow so that it can communicate with other .NET languages in a seamless manner. • Below mentioned the .Net Architecture stack for easy understanding.
  • 10. The components of CLR includes • Class Loader: This loads classes into the runtime. • MSIL to native code compiler: This converts MSIL code into native code. • Code manager: This manager the code during execution i.e provides code check, the resources it needs during execution. • Garbage Collector: provide automatic memory management and avoid memory leaks. • Security Engine: This enforces security restrictions and CAS. • Type Checker: This enforces strict type checking. • Thread Support: This provides multithreading support to applications. • Exception Manager : This provides a mechanism to handle the run-time exceptions. • Debug Engine : Allow you to debug different type of applications. • COM marshaler : This allows .net application to exchange data with COM applications. • BASE Class library : This provides the types the applications needed at runtime.
  • 12. Main components of CLR • Common Language Specification (CLS) • Common Type System (CTS) • Garbage Collection (GC) • Just In – Time Compiler (JIT) Common Language Specification (CLS): • It is responsible for converting the different .NET programming language syntactical rules and regulations into CLR understandable format. Basically, it provides the Language Interoperability. Language Interoperability means to provide the execution support to other programming languages also in .NET framework. Language Interoperability can be achieved in two ways : Managed Code: The MSIL code which is managed by the CLR is known as the Managed Code. For managed code CLR provides three .NET facilities: CAS(Code Access Security)Exception HandlingAutomatic Memory Management.
  • 14. Benefits of CLR: • It improves the performance by providing a richly interact between programs at the run time. • Enhance portability by removing the need of recompiling a program on any operating system that supports it. • Security also increases as it analyzes the MSIL instructions whether they are safe or unsafe. Also, the use of delegates in place of function pointers enhance the type safety and security. • Support automatic memory management with the help of Garbage Collector. • Provides cross-language integration because CTS inside CLR provides a common standard that activates the different languages to extend and share each other’s libraries. • Provides support to use the components that developed in other .NET programming languages. • Provide language, platform, and architecture independency. • It allows the creation of the scalable and multithreaded applications in an easier way as a developer has no need to think about the memory management and security issues. •
  • 15. Language Interoperability can be achieved in two ways : Managed Code: The MSIL code which is managed by the CLR is known as the Managed Code. For managed code CLR provides three . CAS(Code Access Security)Exception HandlingAutomatic Memory Management. Unmanaged Code: Before .NET development the programming language like . Components & Win32 API do not generate the MSIL code. So these are not managed by CLR rather managed by Operating System which is called unmanaged code.
  • 16. Common Type System (CTS): • Every programming language has its own data type system, so CTS is responsible for the understanding all the data type system of . • NET programming languages and converting them into CLR understandable format which will be a common format. • There are 2 Types: • CTS • NET programming language
  翻译: