1. What is meant by the .NET framework?
The Microsoft .NET Framework is a standards-based, language independent application development and execution environment. It consists of a runtime environment called the CLR (common language runtime) and a set of libraries called .NET Class Libraries to enhance programmers’ efficiency and productivity.
2. What are the different types of JIT compilers?
JIT compiler is a part of .NET runtime execution environment. There are three types of JIT compilers, pre-JIT, Econo-JIT and Normal-JIT.
3. What is Microsoft Intermediate Language (MSIL)?
MSIL is a language used as the output of compilers of any .NET-compliant language. During compilation, a source code of any .NET-compliant language is converted to Microsoft Intermediate Language or IL by the compiler, and then the IL code is converted to native code using the just-in-time (JIT) compiler during the runtime.
4. What is CLR?
Common Language Runtime abbreviated as CLR, the execution environment for all programs in the .NET Framework, forms the heart of .NET framework. Its major responsibilities includes Garbage Collection, Code Access Security, Code verification for Type Safety, Intermediate Language to Native translation and optimization. It also provides services such as cross-language integration, object lifetime management, resource management, pre-emptive threading, metadata services like type reflection, and debugging and profiling support. CLR also is known as the Virtual Execution System (VES).
5. What is Managed Code?
Managed code is code executed by Microsoft’s virtual machine such as .NET Framework Common Language Runtime. All IL are managed codes. But if we use some third party software like VB6 they are unmanaged codes and the CLR has no control over those codes.
6. What is Common Language Specification?
The Common Language Specification (CLS) describes a set of features such as data types that different .NET languages have in common. It enables any code to be used by other programs written in different languages.
7. What is CTS?
For two languages to communicate smoothly CLR has Common Type System. For example, in VB we have “Integer” and in C++ we have “long” these data types are not compatible so interfacing between them is very complicated. in order that two different languages communicate Microsoft introduced common type system. So integer data types in VB6 and int data type in C++ will be converted into System.int32 which is data type of CTS.
8. What is an Assembly in .NET Framework?
In the Microsoft .NET Framework, an assembly is a partially compiled code library for use in deployment, versioning, and security. It forms the building block of .NET Framework application. It’s a PE (portable executable) file and could be of two types – process assemblies (EXE) and library assemblies (DLL).
9. What are the contents of an assembly?
* Assembly metadata (called the Assembly Manifest)
* Type metadata
* MSIL code
* Resource files
10. What is a strong name of an assembly?
Strong name of an assembly provides name uniqueness for the assembly. A strong name consists of the assembly’s identity—its simple text name, version number, and culture information (if provided)—plus a public key and a digital signature.
11. What is an Assembly Manifest?
Assembly manifest is a data structure which stores information about an assembly. It contains the assembly metadata needed to specify the assembly’s version requirements, security identity, scope of the assembly and resolve references to resources and classes. The manifest include the assembly identity, version number, public and private keys (if the assembly was built for sharing), a list of components, type reference information, and dependency information.
12. What is a Global Assembly Cache?
The global assembly cache is a machine-wide assembly cache that stores the assemblies specifically designated to be shared by several applications on the computer. This cache makes assemblies available independently of where the application is located. If the assembly cannot be located in the application directory or in the GAC, Common Language Runtime tries to read the application configuration file. Each computer where the CLR is installed has a global assembly cache. It is implemented and managed by the .NET Framework. Shared Location, File Security, Side by Side versioning could be some of the reasons to install an assembly into GAC.
13. What are namespaces?
Namespaces in .NET is a means of semantically grouping elements such as classes to avoid name collisions. A Namespace acts like a containers of objects that creates a hierarchical organization of program. They may contain types such as classes, structures, interfaces, enumerators and delegates. The namespace used by the .Net framework library is System. There are many other namespaces subordinate to System that hold the part of the .NET Base Class Libraries.
14. What is Reflection in .NET?
Reflection is the means by which .NET applications can discover an assembly’s metadata information, its methods and data types exclusively at runtime. Reflection provides runtime querying of types to get/inspect the type information for proper execution, late bound invocation of methods and on the fly creation of Assemblies.
15. What is Code Access Security?
CAS is a part of .NET security model that determines whether or not a piece of code is allowed to run and what resources it can use while running. It helps limit the access code has to protected resources and operations. For example CAS will allow an application to read but not to write and delete a file or a resource from a folder. When the CLR loads an assembly it will obtain evidence for the assembly and use this to identify the code group that the assembly belongs. A code group contains a permission set.
16. What is .NET Remoting?
.NET remoting enables to build widely distributed applications easily and efficiently. The applications can be located on the same computer, different computers on the same network, or even computers across separate networks. .NET Remoting provides a powerful and high performance way of working with remote objects. The implementation is flexible and easily customizable.
17. What is Garbage Collection?
In computing, garbage collection (commonly known as GC) is a form of automatic memory management. The garbage collector attempts to reclaim the memory used by objects that will never be accessed again by the application. Garbage collection in the Microsoft .NET common language runtime environment completely releases the developer from tracking memory usage and knowing when to free memory.
18. What are Web Services?
Web services provide the means for applications to connect to other applications in order to build distributed, service-oriented systems. Web Services are open standard (XML, SOAP, etc.) based small, reusable web applications that interact with other web applications for the basic purpose of exchanging data. They are the kind of applications that help computers from many different operating system platforms work together by exchanging messages. Web services are based on industry protocols that include XML (Extensible Markup Language), SOAP (Simple Object Access Protocol), and WSDL (Web Services Description Language). Web Services could be used to exchange data in large private enterprise networks or even perform transactions over the public Internet.
19. What are collections in .NET?
Collections are the data structures in .NET that provide a means to group objects in logical constructs. They improve code readability and self documentation, as well as enhance maintainability. The various collection classes in .NET framework are Array, ArrayList, Hashtable, SortedList, Queue and Stack. They are all included in System.Collections namespace.
20. What are the four new technologies in .NET framework 3.0?
* WCS (Windows Card Space)
Formerly known as InfoCard, it is a .NET component that provides access to the user’s identities through a desktop interface. It lets any Windows application give its users a common way to work with digital identities.
* WPF (Windows Presentation Foundation)
Formerly code named Avalon, it provides a consistent programming model for building applications and provides a clear separation between the User interface and the business logic.
* WCF (Windows Communication Foundation)
Formerly code named Indigo, built around the Web services architecture; it’s an integrated programming model for building and running connected systems. It enables developers to build secure, reliable, transacted solutions that integrate across platforms and interoperate with existing investments.
* WF (Windows Workflow Foundation)
It’s the programming model, engine and tools for defining, executing, and managing workflows. WF radically enhances a developer’s ability to model and support business processes.
Tags: .NET, .NET FAQ, .NET framework, .net.FAQ, CLR, What are namespaces?, What are the contents of an assembly?, What are the different types of JIT compilers?, What is .NET Remoting?, What is a strong name of an assembly?, What is an Assembly in .NET Framework?, What is CLR?, What is Code Access Security?, What is Common Language Specification?, What is CTS?, What is Garbage Collection?, What is Managed Code?, What is meant by the .NET framework?, What is Microsoft Intermediate Language (MSIL)?, What is Reflection in .NET?