SlideShare a Scribd company logo
1 of 17
Download to read offline
. NET BASED COMPONENT
TECHNOLOGIES
Dr. K.Prakash
Assistant Professor
Kristu Jayanti College
Bengaluru
COM
• Component Object Model (COM) is an interface standard for software
component introduced by Microsoft in 1993.
• It is used to enable interprocess communication and dynamic object
creation in any programming language that supports the technology.
• COM is often used in the software development industry as an umbrella
term that encompasses the OLE, OLE Automation, ActiveX, COM+ and
DCOM technologies.
• The essence of COM is a language-neutral way of implementing objects
that can be used in environments different from the one they were created
in, even across machine boundaries.
• The different allocation semantics of languages are accommodated by
making objects responsible for their own creation and destruction through
reference-counting.
• Casting between different interfaces of an object is achieved through the
QueryInterface() function.
COM
• COM is primarily used with Microsoft Windows. COM is
expected to be replaced at least to some extent by the
Microsoft
• .NET framework, and support for Web Services through the
Windows Communication Foundation (WCF).
• COM objects can still be used with all .NET languages without
problems.
• COM is very similar to other component software interface
standards, such as CORBA and Java Beans, although each has
its own strengths and weaknesses.
DISTRIBUTED COM
• Distributed Component Object Model (DCOM) is a proprietary
Microsoft technology for communication among software
components distributed across networked computers. DCOM, which
originally was called "Network OLE", extends Microsoft's COM, and
provides the communication substrate under Microsoft's COM+
application server infrastructure. It has been deprecated in favor of
Microsoft .NET.
• In terms of the extensions it added to COM, DCOM had to solve the
problems of Marshalling – serializing and deserializing the
arguments and return values of method calls "over the wire".
• Distributed garbage collection – ensuring that references held by
clients of interfaces are released when, for example, the client
process crashed, or the network connection was lost.
OBJECT REUSE
A.java
B.java
C.java
D.java
A.java
• Is the copying of a source file from one
project to another reuse?
• Is the copying of a compiled class file from
one project to another reuse?
Copy
Project 1 Project 2
VERSIONING
• The versioning issue discussed relates to clients of the property.
Suppose we wish to add a new method or property to IHttpContext.
We effectively created a new interface and now all clients need to
recompile. Not only that, but any components you might be using
that refer to IHttpContext need to be recompiled. This can get ugly.
• Adding this method doesn't break older clients. Newer clients who
might need to call this method can recompile and now call this new
method if they wish. This is where we get the versioning benefits.
CONNECTABLE OBJECTS
• The connectable object is only one piece of the overall
architecture of connectable objects. This technology includes the
following elements:
• Connectable object: Implements the IConnectionPointContainer
interface; creates at least one connection point object; defines an
outgoing interface for the client.
• Client: Queries the object for IConnectionPointContainer to
determine whether the object is connectable; creates a sink object to
implement the outgoing interface defined by the connectable object.
• Sink object: Implements the outgoing interface; used to establish a
connection to the connectable object.
• Connection point object: Implements the IConnectionPoint
interface and manages connection with the client's sink.
CONNECTABLE OBJECTS
• The relationships between client,
connectable object, a connection point,
and a sink are illustrated in the following
diagram:
OLE CONTAINERS AND
SERVERS
• A container application is an application that can incorporate
embedded or linked items into its own documents.
• The documents managed by a container application must be able
to store and display OLE document components as well as the
data created by the application itself.
• A container application must also allow users to insert new items
or edit existing items by activating server applications when
necessary.
• A server application or component application is an application that
can create OLE document components for use by container
applications.
• Server applications usually support drag and drop or copying their
data to the Clipboard so that a container application can insert the
data as an embedded or linked item.
OLE CONTAINERS AND
SERVERS
• Most servers are stand-alone applications or full servers; they can either be
run as stand-alone applications or can be launched by a container
application.
• Containers and servers do not communicate directly. Instead, they
communicate through the OLE system dynamic-link libraries (DLL). These
DLLs provide functions that containers and servers call, and the containers
and servers provide callback functions that the DLLs call.
ACTIVEX CONTROLS
• ActiveX is a component object model (COM) developed
by Microsoft for Windows platforms.
• By using the COM runtime, developers can create
software components that perform a particular function
or a set of functions.
• Many Microsoft Windows applications - including many
of those from Microsoft such as Internet Explorer,
Microsoft Office, Microsoft Visual Studio, Windows
Media Player etc - use ActiveX controls to build their
feature set as well as encapsulate their functionality.
• Internet Explorer also allows the ActiveX controls to be
embedded inside web pages.
.NET COMPONENTS
• .NET components provide a programmable interface that is
accessed by consumer applications (often called client
applications).
• .NET object-oriented programming involves not much more than
creating a class, adding the properties, methods, and events required
by the class, and including the class in different applications.
• A .NET component, however, is a pre-compiled class module with a
.DLL (dynamically- linked library) extension. At run time, a .NET
component is invoked and loaded into memory to be used by some
consumer application.
• Each .NET DLL component may contain multiple classes. This means
that each DLL may expose a single class or a variety of classes.
ASSEMBLIES
Assemblies are a fundamental part of programming with the
.NET Framework. An assembly performs the following
functions:
• It contains code that the common language runtime executes.
Microsoft intermediate language (MSIL) code in a portable
executable (PE) file will not be executed if it does not have an
associated assembly manifest. Note that each assembly can have
only one entry point (that is, DllMain, WinMain, or Main)
Boundaries
• Security boundary - An assembly is the unit at which permissions
are requested and granted.
• Type boundary - Every type's identity includes the name of the
assembly in which it resides. A type called MyType loaded in the
scope of one assembly is not the same as a type called MyType
loaded in the scope of another assembly.
• Reference scope boundary - The assembly's manifest
contains assembly metadata that is used for resolving types and
satisfying resource requests.
• Version boundary - The assembly is the smallest versionable
unit in the common language runtime. All types and resources in
the same assembly are versioned as a unit.
AppDomain
• An AppDomain is a light-weight process.
• A Win32 process is heavy-weight compared to a Unix process.
• A Win32 thread is heavy-weight compared to a Unix thread.
• In .NET, threads run in AppDomain.
• AppDomain is analogous to a Win32 process in that it offers many
of the same benefits.
• A thread in one process cannot invoke a method in a thread that
belongs to another process.
• In .NET, however, threads can cross AppDomain boundaries, and a
method in one thread can call a method in another AppDomain.
Therefore, here's a better definition of an AppDomain: a logical
process inside of a physical process.
CONTEXTS
• In computer science, a task context (process, thread ...) is the
minimal set of data used by this task that must be saved to allow a
task interruption at a given date, and a continuation of this task at
the point it has been interrupted and at an arbitrary future date.
These data are located in:
• Processor registers
• Memory used by the task
• Operating systems, control registers used by the system to manage
the task
• The storage memory (files)
REFLECTION
• Reflection can be used for observing and/or modifying program
execution at runtime.
• A reflection-oriented program component can monitor the execution
of an enclosure of code and can modify itself according to a desired
goal related to that enclosure.
• Reflection can also be used to adapt a given program to different
situations dynamically.
• For example, consider an application that uses two different classes
X and Y interchangeably to perform similar operations.
• Without reflection-oriented programming, the application might be
hard-coded to call method names of class X and class Y. However,
using the reflection- oriented programming paradigm, the
application could be designed and written to utilize reflection in
order to invoke methods in classes X and Y without hard-coding
method names.

More Related Content

Similar to .net Based Component Technologies

Similar to .net Based Component Technologies (20)

.NET TECHNOLOGIES
.NET TECHNOLOGIES.NET TECHNOLOGIES
.NET TECHNOLOGIES
 
dot NET Framework
dot NET Frameworkdot NET Framework
dot NET Framework
 
Tech presentation (part 1)
Tech presentation (part 1)Tech presentation (part 1)
Tech presentation (part 1)
 
Presentation1.pptx
Presentation1.pptxPresentation1.pptx
Presentation1.pptx
 
Asp.NETZERO - A Workshop Presentation by Citytech Software
Asp.NETZERO - A Workshop Presentation by Citytech SoftwareAsp.NETZERO - A Workshop Presentation by Citytech Software
Asp.NETZERO - A Workshop Presentation by Citytech Software
 
Introducing object oriented programming (oop)
Introducing object oriented programming (oop)Introducing object oriented programming (oop)
Introducing object oriented programming (oop)
 
Object-Relational Mapping and Dependency Injection
Object-Relational Mapping and Dependency InjectionObject-Relational Mapping and Dependency Injection
Object-Relational Mapping and Dependency Injection
 
Scheduling Thread
Scheduling  ThreadScheduling  Thread
Scheduling Thread
 
Dotnet interview qa
Dotnet interview qaDotnet interview qa
Dotnet interview qa
 
.Net framework
.Net framework.Net framework
.Net framework
 
Asp.net new
Asp.net newAsp.net new
Asp.net new
 
C# and dot net framework
C# and dot net frameworkC# and dot net framework
C# and dot net framework
 
Online lg prodect
Online lg prodectOnline lg prodect
Online lg prodect
 
Clean sw 3_architecture
Clean sw 3_architectureClean sw 3_architecture
Clean sw 3_architecture
 
Eclipse plug in development
Eclipse plug in developmentEclipse plug in development
Eclipse plug in development
 
Introduction to Spring & Spring BootFramework
Introduction to Spring  & Spring BootFrameworkIntroduction to Spring  & Spring BootFramework
Introduction to Spring & Spring BootFramework
 
Oop.pptx
Oop.pptxOop.pptx
Oop.pptx
 
Session2 (3)
Session2 (3)Session2 (3)
Session2 (3)
 
Javascript best practices
Javascript best practicesJavascript best practices
Javascript best practices
 
CS4443 - Modern Programming Language - I Lecture (1)
CS4443 - Modern Programming Language - I Lecture (1)CS4443 - Modern Programming Language - I Lecture (1)
CS4443 - Modern Programming Language - I Lecture (1)
 

Recently uploaded

Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Celine George
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17Celine George
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
Hierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementHierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementmkooblal
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxSayali Powar
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxmanuelaromero2013
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxthorishapillay1
 
CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxJiesonDelaCerna
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Educationpboyjonauth
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxGaneshChakor2
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxAvyJaneVismanos
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfSumit Tiwari
 
Capitol Tech U Doctoral Presentation - April 2024.pptx
Capitol Tech U Doctoral Presentation - April 2024.pptxCapitol Tech U Doctoral Presentation - April 2024.pptx
Capitol Tech U Doctoral Presentation - April 2024.pptxCapitolTechU
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdfssuser54595a
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxEyham Joco
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentInMediaRes1
 

Recently uploaded (20)

Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
Incoming and Outgoing Shipments in 1 STEP Using Odoo 17
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
Hierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of managementHierarchy of management that covers different levels of management
Hierarchy of management that covers different levels of management
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptx
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptx
 
CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptx
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Education
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptx
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
 
Capitol Tech U Doctoral Presentation - April 2024.pptx
Capitol Tech U Doctoral Presentation - April 2024.pptxCapitol Tech U Doctoral Presentation - April 2024.pptx
Capitol Tech U Doctoral Presentation - April 2024.pptx
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptx
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media Component
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 

.net Based Component Technologies

  • 1. . NET BASED COMPONENT TECHNOLOGIES Dr. K.Prakash Assistant Professor Kristu Jayanti College Bengaluru
  • 2. COM • Component Object Model (COM) is an interface standard for software component introduced by Microsoft in 1993. • It is used to enable interprocess communication and dynamic object creation in any programming language that supports the technology. • COM is often used in the software development industry as an umbrella term that encompasses the OLE, OLE Automation, ActiveX, COM+ and DCOM technologies. • The essence of COM is a language-neutral way of implementing objects that can be used in environments different from the one they were created in, even across machine boundaries. • The different allocation semantics of languages are accommodated by making objects responsible for their own creation and destruction through reference-counting. • Casting between different interfaces of an object is achieved through the QueryInterface() function.
  • 3. COM • COM is primarily used with Microsoft Windows. COM is expected to be replaced at least to some extent by the Microsoft • .NET framework, and support for Web Services through the Windows Communication Foundation (WCF). • COM objects can still be used with all .NET languages without problems. • COM is very similar to other component software interface standards, such as CORBA and Java Beans, although each has its own strengths and weaknesses.
  • 4. DISTRIBUTED COM • Distributed Component Object Model (DCOM) is a proprietary Microsoft technology for communication among software components distributed across networked computers. DCOM, which originally was called "Network OLE", extends Microsoft's COM, and provides the communication substrate under Microsoft's COM+ application server infrastructure. It has been deprecated in favor of Microsoft .NET. • In terms of the extensions it added to COM, DCOM had to solve the problems of Marshalling – serializing and deserializing the arguments and return values of method calls "over the wire". • Distributed garbage collection – ensuring that references held by clients of interfaces are released when, for example, the client process crashed, or the network connection was lost.
  • 5. OBJECT REUSE A.java B.java C.java D.java A.java • Is the copying of a source file from one project to another reuse? • Is the copying of a compiled class file from one project to another reuse? Copy Project 1 Project 2
  • 6. VERSIONING • The versioning issue discussed relates to clients of the property. Suppose we wish to add a new method or property to IHttpContext. We effectively created a new interface and now all clients need to recompile. Not only that, but any components you might be using that refer to IHttpContext need to be recompiled. This can get ugly. • Adding this method doesn't break older clients. Newer clients who might need to call this method can recompile and now call this new method if they wish. This is where we get the versioning benefits.
  • 7. CONNECTABLE OBJECTS • The connectable object is only one piece of the overall architecture of connectable objects. This technology includes the following elements: • Connectable object: Implements the IConnectionPointContainer interface; creates at least one connection point object; defines an outgoing interface for the client. • Client: Queries the object for IConnectionPointContainer to determine whether the object is connectable; creates a sink object to implement the outgoing interface defined by the connectable object. • Sink object: Implements the outgoing interface; used to establish a connection to the connectable object. • Connection point object: Implements the IConnectionPoint interface and manages connection with the client's sink.
  • 8. CONNECTABLE OBJECTS • The relationships between client, connectable object, a connection point, and a sink are illustrated in the following diagram:
  • 9. OLE CONTAINERS AND SERVERS • A container application is an application that can incorporate embedded or linked items into its own documents. • The documents managed by a container application must be able to store and display OLE document components as well as the data created by the application itself. • A container application must also allow users to insert new items or edit existing items by activating server applications when necessary. • A server application or component application is an application that can create OLE document components for use by container applications. • Server applications usually support drag and drop or copying their data to the Clipboard so that a container application can insert the data as an embedded or linked item.
  • 10. OLE CONTAINERS AND SERVERS • Most servers are stand-alone applications or full servers; they can either be run as stand-alone applications or can be launched by a container application. • Containers and servers do not communicate directly. Instead, they communicate through the OLE system dynamic-link libraries (DLL). These DLLs provide functions that containers and servers call, and the containers and servers provide callback functions that the DLLs call.
  • 11. ACTIVEX CONTROLS • ActiveX is a component object model (COM) developed by Microsoft for Windows platforms. • By using the COM runtime, developers can create software components that perform a particular function or a set of functions. • Many Microsoft Windows applications - including many of those from Microsoft such as Internet Explorer, Microsoft Office, Microsoft Visual Studio, Windows Media Player etc - use ActiveX controls to build their feature set as well as encapsulate their functionality. • Internet Explorer also allows the ActiveX controls to be embedded inside web pages.
  • 12. .NET COMPONENTS • .NET components provide a programmable interface that is accessed by consumer applications (often called client applications). • .NET object-oriented programming involves not much more than creating a class, adding the properties, methods, and events required by the class, and including the class in different applications. • A .NET component, however, is a pre-compiled class module with a .DLL (dynamically- linked library) extension. At run time, a .NET component is invoked and loaded into memory to be used by some consumer application. • Each .NET DLL component may contain multiple classes. This means that each DLL may expose a single class or a variety of classes.
  • 13. ASSEMBLIES Assemblies are a fundamental part of programming with the .NET Framework. An assembly performs the following functions: • It contains code that the common language runtime executes. Microsoft intermediate language (MSIL) code in a portable executable (PE) file will not be executed if it does not have an associated assembly manifest. Note that each assembly can have only one entry point (that is, DllMain, WinMain, or Main) Boundaries • Security boundary - An assembly is the unit at which permissions are requested and granted. • Type boundary - Every type's identity includes the name of the assembly in which it resides. A type called MyType loaded in the scope of one assembly is not the same as a type called MyType loaded in the scope of another assembly.
  • 14. • Reference scope boundary - The assembly's manifest contains assembly metadata that is used for resolving types and satisfying resource requests. • Version boundary - The assembly is the smallest versionable unit in the common language runtime. All types and resources in the same assembly are versioned as a unit.
  • 15. AppDomain • An AppDomain is a light-weight process. • A Win32 process is heavy-weight compared to a Unix process. • A Win32 thread is heavy-weight compared to a Unix thread. • In .NET, threads run in AppDomain. • AppDomain is analogous to a Win32 process in that it offers many of the same benefits. • A thread in one process cannot invoke a method in a thread that belongs to another process. • In .NET, however, threads can cross AppDomain boundaries, and a method in one thread can call a method in another AppDomain. Therefore, here's a better definition of an AppDomain: a logical process inside of a physical process.
  • 16. CONTEXTS • In computer science, a task context (process, thread ...) is the minimal set of data used by this task that must be saved to allow a task interruption at a given date, and a continuation of this task at the point it has been interrupted and at an arbitrary future date. These data are located in: • Processor registers • Memory used by the task • Operating systems, control registers used by the system to manage the task • The storage memory (files)
  • 17. REFLECTION • Reflection can be used for observing and/or modifying program execution at runtime. • A reflection-oriented program component can monitor the execution of an enclosure of code and can modify itself according to a desired goal related to that enclosure. • Reflection can also be used to adapt a given program to different situations dynamically. • For example, consider an application that uses two different classes X and Y interchangeably to perform similar operations. • Without reflection-oriented programming, the application might be hard-coded to call method names of class X and class Y. However, using the reflection- oriented programming paradigm, the application could be designed and written to utilize reflection in order to invoke methods in classes X and Y without hard-coding method names.