Labels

Thursday, December 30, 2010

What's new in ASP.Net 3.5

One major improvement for Visual Studio 2008 over earlier versions is you can specifically choose the .NET Framework version for an application, allowing it to be used for older .NET 2.0 applications as easily as .NET 3.5 applications.

ASP.NET AJAX

LINQ

There are a number of new controls added to the ASP.NET environment that simplify the display of data on a Web page, as well as provide the user with more flexibility in viewing and selecting data. While ASP.NET 2.0 added several controls for working with data on the Web (notably GridView, DetailsView and FormView), they were restricted in their capabilities and flexibility. Two new controls, ListView and DataPager, are new in ASP.NET 3.5 and are extremely useful.

Support for several standard protocols has been added to ASP.NET 3.5, too. The most common protocols now supported are SOAP (a protocol for moving XML messages, SOAP is a foundation of the Web services protocol stack), RSS (Web feed format for frequently-updated content), JSON (JavaScript Object Notation, a data interchange format), and POX (Plain Old XML, which is actually XML with other specifications such as XML Namespaces, XInclude, XLink and Dublin Core.

ASP.NET 3.5 includes the ASP.NET MVC

New in .NET framework 2.0

It brings a lot of evolution in class of the framework and refactor control including the support of

Generics
Anonymous methods
Partial class
Nullable type
The new API gives a fine grain control on the behavior of the runtime with regards to multithreading, memory allocation, assembly loading and more
Full 64-bit support for both the x64 and the IA64 hardware platforms
New personalization features for ASP.NET, such as support for themes, skins and webparts.
.NET Micro Framework

New in .NET framework 3.0

Also called WinFX,includes a new set of managed code APIs that are an integral part of Windows Vista and Windows Server 2008 operating systems and provides

Windows Communication Foundation (WCF), formerly called Indigo; a service-oriented messaging system which allows programs to interoperate locally or remotely similar to web services.
Windows Presentation Foundation (WPF), formerly called Avalon; a new user interface subsystem and API based on XML and vector graphics, which uses 3D computer graphics hardware and Direct3D technologies.
Windows Workflow Foundation (WF) allows for building of task automation and integrated transactions using workflows.
Windows CardSpace, formerly called InfoCard; a software component which securely stores a person's digital identities and provides a unified interface for choosing the identity for a particular transaction, such as logging in to a website

New in .NET framework 3.5

It implement Linq evolution in language. So we have the following evolution in class:

Linq for SQL, XML, Dataset, Object
Addin system
p2p base class
Active directory
ASP.NET Ajax
Anonymous types with static type inference
Paging support for ADO.NET
ADO.NET synchronization API to synchronize local caches and server side datastores
Asynchronous network I/O API
Support for HTTP pipelining and syndication feeds.
New System.CodeDom namespace.

 

What's new in C#.NET 2005

The new features of C#.NET are classified into four categories:- Generics, Iterators, Anonymous methods and Partial Classes.

Generics were introduced to enable developers create type safe data structures. They can be defined as utility helper classes that do not commit the developer to the actual data types being used. This feature improves performance and results in higher quality code as the algorithms can be reused without duplicating type specific code. They are an extension to the CLR type system and allow developers to define types which are unspecified. They are then specified at runtime as the code references the generic type and fills in the details, tailoring the type to particular needs. Though generics serve a similar purpose as C++ templates in managed code they have some additional features which include absences of code bloat and developer confusion. Four distinct benefits accrue to the developer at compile time—Type safety, binary code reuse, performance and clarity.

Iterators are used to iterate over data structures such as arrays, collections using a foreach loop. The condition being that the GetEnumerator method is implemented to return an IEnumerator interface. C# 2.0 defines the generic type safe IEnumerable and IEnumerator interfaces in System.Collections.Generics namespace to overcome these problems. There is no need to work with a design pattern. A single typed method called GetEnumerator() is sufficient. The values will be returned directly. The new keyword yield replaces the return keyword. The compiler then converts the new implementation into a enumerator pattern and eases the process of development. It avoids unnecessary coding and keeps the source code short. A significant feature is that any method can be made enumerable. The method has to return a value defined by the IEnumerable and use the yield keyword to return a single value.

C#.NET 2.0 supports delegates as means of invoking one or more methods. The Delegates provide operators and methods for adding or removing target methods and are frequently used in .NET Framework for events, callbacks, asynchronous calls and multithreading. Anonymous methods are a new feature in C#.NET 2.0 that lets the developer define an anonymous method called by a delegate. This method is defined inline and is not a member method of any class and there is no way of applying method attributes to it. The anonymous method cannot define generic types or add generic constraints. The compiler has to infer the type of delegate used, instantiate a new delegate object of the inferred type, wrap the new delegate around the anonymous method and assign it to the delegate used in the definition of the anonymous method. Anonymous methods can be used anywhere and can be passed to any method that accepts the appropriate delegate type as a parameter. Anonymous methods can use generic types as parameters.

 Partial Classes are classes whose definition and implementation are split into two or more separate files. Every part of the class is marked with the new modifier partial. The compiler then looks for the marked and parts and merges the component parts and merges them into one complete implementation at runtime. A precondition is that the assembly of the code parts must be in the same project and a parallel compilation. The classes also should be matched logically and must have identical modifiers, supported interfaces etc. All attributes assigned at class level are handled automatically. This feature was directed towards rapid application development and probably for distinguishing between generated and custom code.

What's New in ASP.NET 2.0

1. Improving Development productivity by reducing the lines of code to be written by 70%. Most of the frequently required code is now available out of the box.

2. Making ASP.NET easier to use with existing devices like Web browsers, PDAs, Cell phones and so on with a potential to connect to new devices that may emerge in the future.

3. Increasing performance and scalability for developing fast web applications platforms by providing facilities such as caching.

4. Simplifying the administration and management of web applications

5. Providing enhanced hosting opportunities for Internet Service providers

6. Ensuring 100% backward compatibility.

The team split the process of enhancement into three parts:--Application services, Page effects and Rich controls. They focused on each of these parts to come up with an application development platform that is exciting and extremely developer friendly.

We shall briefly look at these enhancements in this section.

New Controls

It is expected that the final release of ASP.NET will include 40 new controls. The existing controls will be retained to ensure backward compatibility.

The data controls have received a face lift. The Grid View control has features for sorting, paging, selection and editing of contents out of the box. The communication with the database is transparently handled and is enabled for both reading and writing data to the database.

The DetailsView control displays single records in a vertical listing of data. This control can be configured to provide for custom outputs.

The TreeView control supports the Data Source Provider concept and a number of data sources can be bound to it, including XML data.

The Bulleted list control designed for data binding displays highly configurable HTML lists and provides support for hyperlinks and link buttons.

Apart from the above major new controls a number of other new controls have been introduced to for use of image maps, upload of files and rapid implementation of Wizards.

Master Pages

Master pages have been designed to help web developers design templates with place holders for content. Unlike in the earlier versions of ASP.NET developers can now rely on visual design support to design their pages.

Site Navigation

Implementation of navigation has been made simple with the integrated navigation structure based on XML data. The provider does the job of feeding the navigation structure with data instead of using the site map support. The provider acts as a bridge between the common framework functions and custom implementation.

User Management

An entire user management system is provided out of the box! Extensive API, special controls for registration, login and so on with data providers to handle the data storage without any code are the highlights of this feature. The configuration user management system and the creation of the database is also assisted by a Wizard. The administration feature helps the developer decide how passwords will be stored, reset and so on and also enables the management of user roles.

Personalization

Personalization makes it possible to assign information to an user account, save it to persistent storage and automatically load it back for the next session. This feature can be used in conjunction with the user management system. Complex data structures like shopping carts can also be persisted using XML serialization. The personalization feature also allows users define one or more zones and within the zone information (web parts) can be arranged using drag and drop. This implies that content can be moved, changed or deleted with ease. The Data Provider takes care of the data storage, freeing the developer from designing ways and means of storing data. All data can be stored in SQL Server or Microsoft Access database.

Themes and Skins

With the new ASP.NET allows developers define themes and skins for their applications. The only effort required is the definition of the theme. Some sample themes are included in the standard installation and they can be activated by making some configuration adjustments in the application. The Implementation of themes provides for design properties, CSS support and integration of individual graphics. A theme and a sub theme(called skin) can be local to the application, the page or the control.

Mobile devices

Mobile computing has been taken to new heights with ASP.NET 2.0. Controls for mobile devices included in ASP.NET 1.1 are still available but are not recommended for use. The new ASP.NET introduces the concept of “adaptive rendering” which makes controls redundant. Regular web controls will adapt to the requirements of the target device! A set of adapter classes have been defined and assigned to each control and they are included for common browsers and mobile devices. Customized adapters can also be defined by the developer. This leaves Microsoft with the option to add adapters for new devices that may enter the market in the future.

Site Counters

This feature helps in counting page requests and also clicks of controls (e.g. AdRotator, Button, link button etc). The .NET framework provides an extensive API to analyze, visualize and process the data.

Configuration

The new ASP.NET does away with the cumbersome configuration files of its earlier versions. The voluminous API to read and write configuration files like web.config in type safe manner makes the whole job easier. Each object gets one corresponding configuration segment and a whole collection where necessary. These objects can be edited and then saved back to the file. In the process every setting in the web application can be controlled by the developer. Web Site Administration tools and Configuration Settings Editor are two major additions under this head.

Deployment

ASP.NET 2.0 opens up several new possibilities for the deployment of the applications. Developers can now create or open projects using the file system or the local IIS, FrontPage Extensions or even FTP. The Web Copy Assistant supports the synchronization of local development version with the live server. The new functionality for compiling complete web applications includes copying of Dynamic link Libraries(DLLs) to the Web server. These libraries contain compiled source code and the content of the aspx and ascx files. This implies that no design time files will be required to be placed on the server and hence modification of the application becomes difficult.

The new features of Visual Studio.NET 2.0 and its repository of software including ASP.NET, C#.NET etc are dedicated solutions created to address specific problems of the developer. It attempts to simplify the overall programming model. The compiler is designed to generate most of the code and the developer is freed from repetitive programming tasks. Code has become more concise and readable.