UNDERSTANDING .NET ASSEMBLIES
#1

[attachment=10221]
3.1 UNDERSTANDING .NET ASSEMBLIES
Q1) Define Assembly. What are the benefits provided by net assemblies?
Answer:
Definition of assembly
The term assembly refers to a group of files grouped together to form a single file “.dll file ”or “.exe file ”. It is one of the major parts of the .Net components. A dll file is called during execution of a program. This file contains methods and classes.
The major funct ionalities of assembly is as follows:
1. it provides security
2. it provides code reusability
3. It provides versioning
4. It provides deployment.
Assembly is categorized in two ways,
(a) Shared assembly
(b) Private assembly.
Assembly contains metadata, data of the application program, definition of the class, .gif files etc.
Benefits of Assembly
The benefits of .net assembly are,
a) It provides code reusability
b) I t provides Boundary condition
c) It assigns version numbers
d) It is self-describing
e) It is configurable.
(a) Code reusability
The .net code is placed is an executable file or dll file which contains predefined libraries called class library/ code library. These libraries can be reused by other languages of the .net family.
For example, the code in an asp.net can be used by the C#.net.
(b) Boundary condition
.Net provides predefined namespaces which is prefixed to the class name and maintains boundaries conditions.
Example:-
System. Console. Write Line
System.Data
In the above example, system is a namespace followed by class i.e., console and data. © Version Number
.Net supports four bits of version number. It is given by <major>.<minor>.<build>.<revision>. The default version number is given as 0.0.0.0. Multiple version numbers can be obtained by us ing the public key value of the same machine this typed of versioning is called “strong name type version ”. //StudentRockStars.com
(d) Self –describing
Assemblies ’aer self – describing, they describe the manifest information and metadata. Where manifest information is a collection of metadata which describes the entire assembly. Metadata contains the methods and class information.
(e) Configurable
Assemblies can be configured into two types,
(i) Shared assembly
(ii) Private assembly
(i)Shared Assembly:-
Thi s assembly can be shared by many users of a same machine by using a directory called ‘Global Assembly Cache ’(GAC)
(ii) Private assembly:-
This type of assembly can ’t be shared; it is accessed by a single user only in a single folder. XML configuration informs us which assembly should be used, its version number and network location.
Q2) Discuss the various elements of .Net assembly.
Elements of .Net assembly :
.net assembly provides elements they are as,
(i) File header
(ii) CIL code
(iii) Meta data
(iv) Manifest
(v) Resources. //StudentRockStars.com
(i) File Headers
.Net assembly provides two types of file headers
a) win32 file header
b) CLR file header.
(a) Win32 file header
This file header provides the block of information which provides the type of app lication generated by this header such as, GUI application, console application, dll application etc. (b) CLR file header
This file header maintains the flags which help in understanding the layout of the managed file these flags contain the information about version number, resources, metadata, public key etc., ‘C ’header maintains an unmanaged code, this data can be neglected as it is not managed data. i i) CIL code
CIL stands for common - intermediate language generated by the .Net assembly. This cod e will be complied by JIT (just- in -time) complier which is used to convert all the managed codes, (source code) into CIL code (destination code).
iii) Metadata
Metadata is used for displaying the entire information of the assembly which includes types, i nterface, methods, clouses, delegates, libraries, structure etc.
iv) Manifest
Manifest is a part of metadata provided by the .Net assembly like version number, libraries, list of modules, list of assemblies, resources, etc.
v) Resources
resources is nothing but files or components used in an assembly such as sound clips, string tables, image files icons etc., satellite assembly is used to concentrate partition the resources for developing software.
Structure of assembly diagram is shown below.
Reply

Important Note..!

If you are not satisfied with above reply ,..Please

ASK HERE

So that we will collect data for you and will made reply to the request....OR try below "QUICK REPLY" box to add a reply to this page
Popular Searches: training understanding financial, win32 createthread, tolerant and understanding, aircraft control cable assemblies, understanding internet its advancement in future, understanding digital, for example the automated inspection of electronic assemblies interest lies in analyzing images of the products with the obje,

[-]
Quick Reply
Message
Type your reply to this message here.

Image Verification
Please enter the text contained within the image into the text box below it. This process is used to prevent automated spam bots.
Image Verification
(case insensitive)

Possibly Related Threads...
Thread Author Replies Views Last Post
  ASP.NET questions, part 1 seminar class 0 1,871 02-03-2011, 09:43 AM
Last Post: seminar class

Forum Jump: