.NET Aims And Objectives



Microsoft .NET (Microsoft dotNet) is a set of Microsoft software technologies for connecting your world of information, people, systems, and devices.
A
It enables an unprecedented level of software integration through the use of XML Web services: small, discrete, building-block applications that connect to each other—as well as to other, larger applications—via the Internet.



The Goal

The goal that Microsoft has set itself is ambitious, to say the least, both in technical and strategic terms. The new .NET platform has not evolved from the DNA 2000 technology currently available; rather, it is a totally new technology which is likely to shake up more than a few deep-rooted ideas.
.NET is an entirely new platform and technology which introduces a host of new products, whose compatibility with existing technology is not always guaranteed. It offers support for 34 programming languages, which share a hierarchy of classes providing basic services. .NET applications no longer run in native machine code, having abandaned Intel x86 code in favor of an intermediate language called MSIL which runs in a sort of virtual machine called the Common Language Runtime (CLR).
In addition, .NET makes intensive use of XML, and places a lot of emphasis on the SOAP protocol. Thanks to SOAP, Microsoft is hoping to bring us into a new era of programming which, rather than relying on the assembly of components or objects, is based on the reuse of services. SOAP and Web Services are the cornerstones of the .NET platform.
Microsoft .Net (Microsoft dotNet) aims to reduce the cost of software development by creating re-useable code that can be used by all applications in the environment, regardless of operating system or programming language.

You may develop (or purchase) a Microsoft .Net (Microsoft dotNet) web based application that takes new sales orders over the Internet. Dot net will allow you to call the logic behind the application from any other program. For example Microsoft Excel or Word macros could directly call the web based application to create new sales order. A customer could easily and securely develop their own application interface that directly and securely places a new sales order on your website.
Microsoft .NET Framework is a computing platform for developing distributed applications for the Internet. Following are the design goals of Microsoft .NET Framework:
  1. To provide a very high degree of language interoperability
  2. To provide a runtime environment that completely manages code execution
  3. To provide a very simple software deployment and versioning model
  4. To provide high-level code security through code access security and strong type checking
  5. To provide a consistent object-oriented programming model
  6. To facilitate application communication by using industry standards such as SOAP and XML.
  7. To simplify Web application development



.NET is multi-language

With the .NET platform, Microsoft will provide several languages and the associated compilers, such as C++, JScript, VB.NET (alias VB 7) and C#, a new language which emerged with .NET.

Third party vendors working in partnership with Microsoft are currently developing compilers for a broad range of other languages, including Cobol, Eiffel, CAML, Lisp, Python and Smalltalk. Rational, vendor of the famous UML tool Rose, is also understood to be finalizing a Java compiler for .NET.



Applications are hardware-independent

All these languages are compiled via an intermediate binary code, which is independent of hardware and operating systems. This language is MSIL: Microsoft Intermediate Language. MSIL is then executed in the Common Language Runtime (CLR), which basically fulfills the same role as the JVM in the Java platform. MSIL is then translated into machine code by a Just in Time (JiT) compiler.



Applications are portable

Applications compiled as intermediate code are presented as Portable Executables (PEs). Microsoft will thereby be able to offer full or partial implementations of the .NET platform over a vast range of hardware and software architectures: Intel PCs with Windows 9x, Windows NT4, Windows 2000 or future 64 bit Windows versions, microcontroller-based PDAs with PocketPC (e.g. Windows CE), and other operating systems too, no doubt.



All languages must comply with a common agreement

Existing computer languages are heterogeneous: some are procedural, others object-oriented, some authorize use of optional parameters or a variable number of parameters, some authorize operator overload, others do not, and so it goes on.

For a language to be eligible for the range of languages supported by the .NET platform, it must provide a set of possibilities and constructions listed in an agreement called the Common Language Specification, or CLS. To add a language to .NET, all that is required in theory is for it to meet the requirements of the CLS, and for someone to develop a compiler from this language into MSIL.

The fact that all the .NET languages are compiled in the form of an intermediate code also means that a class written in a language may be derived in another language, and it is possible to instantiate in one language an object of a class written in another language.

.NET Web Services


A web service is a standard platform for building interoperable distributed applications.



What’s a Web Service?

A web service is a standard platform for building interoperable distributed applications. It allows you as a developer, to interact with other information providers without worrying about what they are running either at the backend or even their front-end.
Web Services are pieces of program logic that are programmatically available via the Internet. These pieces of program logic which are in the form of objects, can be invoked from any client over HTTP (Hypertext Transfer Protocol). It functions primarily through XML in order to pass information back and forth through HTTP. By allowing data interchange in the standard XML format, anybody can pick up the data and use it.
Basically, you can author a web service and make its properties and methods available to other developers across the web, without writing vast amounts of documentation for an API or distributing DLLs to everyone who wishes to use them.
In a typical web services scenario, a business application sends a request to a service at a given URL, using the SOAP protocol over HTTP. The service receives the request, processes it, and returns a response. An often-cited example of a web service is that of a stock quote service, in which the request asks for the current price of a specified stock, and the response gives the stock price. This is one of the simplest forms of a web service in that the request is filled almost immediately.
A Web Service is defined as "a component of programmable application logic that can be accessed using standard web protocols". It's basically a component, or an assembly in ASP.NET, that can be accessed over the web.
The concept of sending messages between servers or remotely calling functions is not new. Technologies such as DCOM (Distributed Component Object Model) and CORBA (Common Object Request Broker Architecture) are well-known proprietary protocols that have been in use for years.
What is new is, web services use a standard protocol called SOAP to transfer messages over HTTP. SOAP makes it possible for applications written in different languages running on different platforms to make remote procedure calls (RPC) effectively, even through firewalls.

DCOM doesn't use port 80, which is reserved for HTTP traffic; this causes DCOM calls to be blocked by firewalls. SOAP calls use port 80, which makes it possible to call procedures that exist behind firewalls.



Protocols Used By Web services

Web services use the standard web protocols HTTP, XML, SOAP, WSDL, and UDDI.

HTTP

HTTP (Hypertext Transfer Protocol) is the set of rules for transferring files (text, graphic images, sound, video, and other multimedia files) on the World Wide Web. As soon as a Web user opens their Web browser, the user is indirectly making use of HTTP. HTTP is an application protocol that runs on top of the TCP/IP suite of protocols (the foundation protocols for the Internet).
HTTP is standardized by the World Wide Web Consortium (W3C).
HTTP is called a stateless protocol because each command is executed independently, without any knowledge of the commands that came before it. This is the main reason that it is difficult to implement Web sites that react intelligently to user input. This shortcoming of HTTP is being addressed in a number of new technologies, including ActiveX, Java, JavaScript and cookies.

XML

XML(Extensible Markup Language), a specification developed by the W3C. XML is a pared-down version of SGML, designed especially for Web documents. It allows designers to create their own customized tags, enabling the definition,transmission, validation, and interpretation of data between applications and between organizations.

SOAP

SOAP(Simple Object Access Protocol), a lightweight XML-based messaging protocol used to encode the information in Web service request and response messages before sending them over a network. SOAP messages are independent of any operating system or protocol and may be transported using a variety of Internet protocols, including SMTP, MIME, and HTTP.

WSDL

WSDL(Web Services Description Language), an XML-formatted language used to describe a Web service's capabilities as collections of communication endpoints capable of exchanging messages. WSDL is an integral part of UDDI, an XML-based worldwide business registry. WSDL is the language that UDDI uses. WSDL was developed jointly by Microsoft and IBM.

UDDI

UDDI(Universal Description, Discovery and Integration). A Web-based distributed directory that enables businesses to list themselves on the Internet and discover each other, similar to a traditional phone book's yellow and white pages.
UDDI is a public registry, where one can publish and inquire about web services.

.NET Software

.NET Framework is designed for cross-language compatibility.
Cross-language compatibility means .NET components can interact with each other irrespective of the languages they are written in.



Languages supported by .NET Framework

The table below lists all the languages supported by the .NET Framework and describes those languages. The languages listed below are supported by the .NET Framework upto the year 2003. In future there may be other languages that the .NET Framework might support.
Language Description/Usage
APL
APL is one of the most powerful, consistent and concise computer programming languages ever devised. It is a language for describing procedures in the processing of information. It can be used to describe mathematical procedures having nothing to do with computers or to describe the way a computer works.
C++
C++ is a true OOP. It is one of the early Object-Oriented programming languages. C++ derives from the C language.
VC++
Visual C++ is the name of a C++ compiler with an integrated environment from Microsoft. This includes special tools that simplify the development of great applications, as well as specific libraries. Its use is known as visual programming.
C#
C# called as C Sharp is a full fledged Object-Oriented programming language from Microsoft built into the .NET Framework. First created in the late 1990’s was part of Microsoft’s whole .NET strategy.
Cobol
COBOL (Common Business Oriented Language) was the first widely-used high-level programming language for business applications. It is considered as a programming language to have more lines of code than any other language.
Component Pascal
Component Pascal is a Pascal derived programming language that is specifically designed for programming software components.
Curriculum No information.
Eiffel
Eiffel is an Object-Oriented (OO) programming language which emphasizes the production of robust software. Eiffel is strongly statically typed mature Object-Oriented language with automatic memory management.
Forth
Forth is a programming language and programming environment. It features both interactive execution of commands (making it suitable as a shell for systems that lack a more formal operating system), as well as the ability to compile sequences of commands into threaded code for later execution.
Fortran
Acronym for Formula Translator, Fortran is one of the oldest high-level programming languages that is still widely used in scientific computing because of its compact notation for equations, ease in handling large arrays, and huge selection of library routines for solving mathematical problems efficiently.
Haskell
Haskell is a computer programming language that is a polymorphicly typed, lazy, purely functional language, quite different from most other programming languages. It is a wide-spectrum language, suitable for a variety of applications. It is particularly suitable for programs which need to be highly modifiable and maintainable.
Java Language
The Java language is one of the most powerful
Object-Oriented programming languages developed till date. It's platform independence (not depending on a particular OS) feature makes it a very popular programming language.
Microsoft JScript
Microsoft JScript is the Microsoft implementation of the ECMA 262 language specification. JScript is an interpreted, object-based scripting language. It has fewer capabilities than full-fledged Object-Oriented languages like C++ but is more than sufficiently powerful for its intended purposes.
Mercury
Mercury is a new logic/functional programming language, which combines the clarity and expressiveness of declarative programming with advanced static analysis and error detection features. Its highly optimized execution algorithm delivers efficiency far in excess of existing logic programming systems, and close to conventional programming systems. Mercury addresses the problems of large-scale program development, allowing modularity, separate compilation, and numerous optimization/time trade-offs.
Mondrian
Mondrian is a simple functional scripting language for Internet applications. It is a functional language specifically designed to
inter-operate with other languages in an OO environment. Current versions of Mondrian run on .NET. Mondrian also supports ASP.NET, allowing you to embed functional language code in web pages along with C# code.
Oberon
Oberon is a programming language very much like Modula-2 in syntax but with several interesting features. It's based on OOP concepts and provides a Windows-based graphical user interface.
Oz
Oz is a high-level programming language that combines constraint inference with concurrency. Oz is dynamically typed and has first-class procedures, classes, objects, exceptions and sequential threads synchronizing over a constraint store. It supports finite domain and feature constraints and has powerful primitives for programming constraint inference engines at a high level.
Pascal
Principle objectives for Pascal were for the language to be efficent to implement and run, allow for the development of well structured and well organized programs, and to serve as a vehicle for the teaching of the important concepts of computer programming. The Prime area of application that Pascal entails is the learning environment. This language was not really developed to be used for anything other than teaching students the basics of programming as it was originally developed for this purpose.
Perl
Practical Extraction and Report Language, Perl, is a language optimized for scanning arbitrary text files, extracting information from those text files, and printing reports based on that information. It's also a good language for many system management tasks.
Python
Python is an interpreted, interactive, Object-Oriented programming language. Python combines remarkable power with very clear syntax. It has modules, classes, exceptions, very high level dynamic data types, and dynamic typing.
RPG
Report Program Generator, RPG, is used for generation of reports from data files, including matching record and sub-total reports. RPG is one of the few languages created for punch card machines that is still in common use today. RPG or RPG IV is a native programming language for IBM's iSeries minicomputer system.
Scheme
Scheme is a statically scoped programming language. It was designed to have an exceptionally clear and simple semantics and few different ways to form expressions. A wide variety of programming paradigms, including imperative, functional, and message passing styles, find convenient expression in Scheme.
Small Talk
SmallTalk is an expressive language that uses a simple sub set of human languages, nouns and verbs. Smalltalk was the first, and remains one of the few, pure object systems, which simply means that everything in a Smalltalk program is an object. Smalltalk is generally recognized as the second Object Programming Language (OPL).
Standard ML
Standard ML is a safe, modular, strict, functional, polymorphic programming language with compile-time type checking and type inference, garbage collection, exception handling, immutable data types and updatable references, abstract data types, and parametric modules. It has efficient implementations and a formal definition with a proof of soundness.
Microsoft Visual Basic
Visual Basic is a "visual programming" environment for developing Windows applications. Visual Basic makes it possible to develop complicated applications very quickly. This site is all about Visual Basic.



Visual J# .NET

Microsoft Visual J#™ .NET is a development tool for Java-language developers who want to build applications and services on the Microsoft .NET Framework. Visual J# .NET joins more than 20 previously announced languages with its ability to target the .NET Framework and first-class XML Web services.
Visual J# .NET provides:
  • The easiest transition for Java-language developers into the world of XML Web services.
  • Dramatically improved interoperability of Java-language programs with existing software written in a variety of other programming languages.
  • The opportunity for Microsoft Visual J++® customers and other Java-language programmers to take advantage of existing investments in skills and code while fully utilizing the Microsoft platform today and into the future.
Visual J# .NET includes technology that enables customers to migrate Java-language investments to the .NET Framework. Existing applications developed with Visual J++ can be easily modified to execute on the .NET Framework, interoperate with applications created with other supported languages on the .NET Framework, and incorporate new technologies supported in the .NET Framework such as Microsoft ASP.NET, Microsoft ADO.NET, and Microsoft Windows® Forms. Further, developers can use Visual J# .NET to create entirely new applications based on the .NET Framework.

.NET Building Blocks

.NET Building Blocks is a set of core Internet Services.



Building Blocks of Microsoft.NET Platform.

Building Blocks of Microsoft.NET Platform



Web Services

Web Services provide data and services to other applications.

Future applications will access Web Services via standard Web Formats (HTTP, HTML, XML, and SOAP), with no need to know how the Web Service itself is implemented.

Web Services are main building blocks in the Microsoft .NET programming model.



Standard Communication

Official Web standards (XML, UDDI, SOAP) will be used to describe what Internet data is, and to describe what Web Services can do.

Future Web applications will be built on flexible services that can interact and exchange data, without the loss of integrity.



Internet Storages

.NET offers secure and addressable places to store data and applications on the Web. Allowing all types of Internet devices (PCs, Palmtops, Phones) to access data and applications.

These Web Services are built on Microsoft's existing NTFS, SQL Server, and Exchange technologies.



Internet Dynamic Delivery

Reliable automatic upgrades by demand and installation independent applications.

.NET will support rapid development of applications that can be dynamically reconfigured.



Internet Identity

.NET supports many different levels of authentication services like passwords, wallets, and smart cards.

These services are built on existing Microsoft Passport and Windows Authentication technologies.



Internet Messaging

.NET supports integration of messaging, e-mail, voice-mail, and fax into one unified Internet Service, targeted for all kinds of PCs or smart Internet devices.

These services are built on existing Hotmail, Exchange and Instant Messenger technologies.



Internet Calendar

.NET supports Internet integration of work, social, and private home calendars. Allowing all types of Internet devices (PCs, Palmtops, Phones) to access the data.

These services are built on existing Outlook and Hotmail technologies.



Internet Directory Services

.NET supports a new kind of directory services that can answer XML based questions about Internet Services, far more exactly than search engines and yellow pages.

These services are built on the UDDI standard.

Introduction to .NET

  • A new platform for building Internet applications and Web services
  • Contains runtime, messaging, services, data access, interoperability, HTTP services, ASP+, and more
  • Supports multi-language development
  • Has a rich set of internet-supporting technologies
  • A common class library with a standard set of classes which all inherits from a base class called Object
  • The .Net Frameworks Object Model is called VOS - Virtual Object System



NGWS - Next Generation Windows Services

Dot Net was originally called NGWS.

Before the official announcement of Dot Net, the term NGWS was used for Microsoft's plans for producing an "Internet-based platform of Next Generation Windows Services".

This new family of Microsoft .NET products and technologies replaces the previous working title of Next Generation Windows Services (NGWS) and includes software for developers to build next-generation Internet experiences as well as power a new breed of smart Internet devices. Microsoft also announced plans for new products built on the .NET platform, including new generations of the Microsoft Windows® operating system, Windows DNA servers, Microsoft Office, the MSN™ network of Internet services and the Visual Studio® development system.



.NET Internet Standards

.NET depends on four Internet standards:

  • HTTP, the communication protocol between Internet Applications
  • XML, the format for exchanging data between Internet Applications
  • SOAP, the standard format for requesting Web Services
  • UDDI, the standard to search and discover Web Services



What Does .NET Give You?

  • Data access
  • Functionality of the Win 32 API that is accessible through a simple object model
  • The VB language has been upgraded
  • C#
  • Memory management
  • ASP.NET
  • Programming languages have been moved closer together
  • Assembly

.NET FRAMEWORK

The .NET Framework is a common environment for building, deploying, and running Web Services and Web Applications.

 The .NET Framework contains common class libraries - like ADO.NET, ASP.NET and Windows Forms - to provide advanced standard services that can be integrated into a variety of computer systems.

 The .NET Framework is language neutral. Currently it supports C++, C#, Visual Basic, JScript (The Microsoft version of JavaScript) and COBOL. Third-party languages - like Eiffel, Perl, Python, Smalltalk, and others - will also be available for building future .NET Framework applications. 

 The new Visual Studio.NET is a common development environment for the new .NET Framework. It provides a feature-rich application execution environment, simplified development and easy integration between a number of different development languages.

.NET Framework



Languages Supported By .NET

Languages Supported By .NET



Common Type System and CLS

CLS(Common Language Specification) Compliant Attribute
  • A subset of Common Type System
  • Assembly can be tagged with[assembly: System.CLSCompliant(true)] Compiler issues a warning if non compliant types are used.
  • Solves the cross language access problem in COM (e.g C++ has types that is not supported by VB)
  • (Private) types, methods may still be marked with [CLSCompliant(false)]
CTS



ASP.NET and Web Forms

ASP.NET and Web Forms



Windows Forms

  • Components needed to create windows applications
  • WIN32 at last hidden with real OOP!
  • Visual Inheritance
  • Same controls used from all languages
  • Consistent naming of properties, methods and behaviour!!!!
  • Forms + Listboxes, Buttons etc
  • WIN32 specific
    • Builds pretty much on intrinsic WIN32 functionality
    • Makes it difficult to support.



Database Support in .NET

  • Create your database
  • Use Visual Studio to create Datalink and typed dataset out of your database.
  • open OleDbConnection
  • OleDbDataAdapter for SQL command
  • Use the adapter to fill out your custom dataset with the requested information
  • Modify your dataset
  • Create update command with the OleDbCommandBuilder
  • Update the database with the adapter (given your dataset)
Database Support in .NET


XML Support

  • XML Is used everywhere
  • Store / Retrieve Datasets in XML
  • XMLTextReader, XMLTextWriter
  • XMLDataDocument
    • W3C Document Object Model (DOM)
  • XMLNode
  • XPath, XslTransform
  • XMLSerialization
  • . . .



Base Class Library

The Base Class Libraries (BCL) provides the fundamental building blocks for any application you develop, be it an ASP.Net application , a Windows Forms application, or a Web Service. The BCL generally serves as your main point of interaction with the runtime.BCL classes include
Base Class Library Namespaces
Namespace Description
System
This namespace includes all the essential support you need for your programming, including base types (String, Int32, DateTime, Boolean, etc.), essential environmental support, and math functions, to name a few
System.CodeDom
all the support necessary to be able to create code, and run it, on the fly
System.Collections
The System.Collections namespace contains interfaces and classes that define various containers, such as lists, queues, bit arrays, hashtables and dictionaries.
System.Diagnostics
All the classes you need to diagnose your application, including event logging, performance counters, tracing, and process management APIs.
System.Globalization
This namespace includes fundamental support for Globalization, used throughout the rest of the Framework
System.IO
Includes fundamental Stream support which can be used by anyone, and then specifically targets the FileSystem (via File and Directory manipulation classes), SerialPorts, and Decompression
System.Resources
Used to allow an application to be translated into multiple languages, and then display the appropriate text based upon the current users language selection
System.Text
This namespace includes support for encodings, and Stringbuilder
System.Text.RegularExpressions
This namespace includes regular expression support, for robust parsing and matching of string data



Common Language Runtime

The Common Language Runtime (CLR) provides a solid foundation for developers to build various types of applications. Whether you're writing an ASP.Net application , a Windows Forms application, a Web Service, a mobile code application, a distributed application, or an application that combines several of these application models, the CLR provides the following benefits for application developers:
  • Vastly simplified development
  • Seamless integration of code written in various languages
  • Evidence-based security with code identity
  • Assembly-based deployment that eliminates DLL Hell
  • Side-by-side versioning of reusable components
  • Code reuse through implementation inheritance
  • Automatic object lifetime management
  • Self describing objects
Common Language Runtime
Common Language Runtime(simplified)
The CLR is the execution environment provided by the Microsoft .NET Framework. It provides many services such as
  • Automatic garbage collection
  • Code access security
  • Simplified versioning
  • Simple and reliable deployment
  • Deep cross-language interoperability
  • Debugging across different languages
  • Performance
  • Scalability
Because the CLR manages the code execution, all the code that is targeted for the CLR is known as managed code. Managed code emits metadata along with the executable. This metadata is used to describe the types (classes) and members used in the code, along with all the external references used in executing the code. The CLR uses this metadata to load the classes during execution and resolve method invocations during runtime.
The CLR provides automatic garbage collection of the objects that have been loaded into memory. All objects that are created via the new operator are allocated memory on the heap. A program can allocate as many objects as are required by the program logic. However, when an object is no longer required, there must be some mechanism to free up the memory that was occupied by the object.
This is accomplished in the CLR via a program called garbage collector, which collects all objects in memory that have no references. This program runs as a low-priority thread in the background process and collects all unreferenced objects. Because memory management is automatic, the chances for memory leaks in the program are minimized. However, the time when garbage collector would actually release the objects from the memory is not known. This concept is known as nondeterministic garbage collection because it cannot be determined in advance when the objects would be released from memory.
If sufficient memory is not available for creating new objects, the CLR throws an exception that can be caught and gracefully handled by the application.
Code Access Security (CAS), as the name suggests, is used to control the access that the code has to system resources. The CLR has a runtime security system. Administrators can configure policy settings by specifying the resources that can be accessed by the code.
A call stack is created that represents the order in which the assemblies get called. The CLR's security system walks the stack to determine whether the code is authorized to access the system resources or perform certain operations. If any caller in the call stack does not have the requisite permission to access the specific system resources, a security exception is thrown by the CLR.
Simplified versioning is another feature provided in the .NET Framework. It supports versioning and also provides for side-by-side execution of different versions of the same component. The specific versions of the assembly and the dependent assemblies are stored in the assembly's manifest. The copies of the same assembly that differ only in version numbers are considered to be different assemblies by the CLR.
Simplified deployment is one of the features provided in the .NET Framework. The most important point to mention is that .NET components do not need to be registered in the Windows registry. All code generated in the .NET Framework is self-describing because assemblies contain the manifest and metadata information. This information contains all the data about the dependencies of the assembly and the specific versions of the components that these assemblies would use at execution time; therefore, multiple versions of the same components can coexist. The CLR enforces the versioning policy.
Cross-language interoperability is an important feature, and it was one of the design goals of the .NET Framework. This feature is possible because of the CTS and CLS.
Visual Studio .NET allows for debugging across an application consisting of different languages targeted for the CLR. In fact, the IDE also allows for debugging an application in which managed code interacts with unmanaged code.
CLR ensures that performance of the code execution is optimized. Compiled code is stored in cache. When the same code is called next time, this code is loaded into memory from cache. This advantage stands out more in the case of ASP.NET applications than for ASP applications. ASP code was interpreted every time an ASP page was requested. In ASP.NET, the code is compiled only once when the page is requested for the first time. This ensures that performance is optimized.
The .NET Framework also provides some classes for tracking the performance of the .NET applications. These classes are known as performance counters. The .NET Framework provides performance counters for getting information on exception handling, interoperation with unmanaged code, loading and unloading code into memory, locking and threading, memory, networking operations, and so on. These performance counters help to fine-tune the performance of the .NET applications.



COM+ Services

Evolution of COM