Tuesday, July 17, 2007

Windows Workflow Foundation

What is Windows Workflow Foundation ?
Windows Workflow Foundation ( WF) is the programming model, engine and tool for quickly building workflow enabled applications. WF radically enhances a developer’s ability to model and support business processes.

Monday, July 16, 2007

Windows Communication Foundation

What is Windows Communication Foundation ?

WCF simplifies development of connected applications through a new service-oriented programming model. WCF supports many styles of distributed application development by providing a layered architecture. At its base, the WCF channel architecture provides asynchronous, untyped message-passing primitives. Built on top of this base are protocol facilities for secure, reliable, transacted data exchange and broad choice of transport and encoding options.

Problem Statement
The following example illustrates some of the problems that WCF addresses. A car rental company decides to create a new application for reserving cars. The creators of this rental car reservation application know that the business logic it implements must be accessible by other software running both inside and outside their company. Accordingly, they decide to build it in a service-oriented style, with the application’s logic exposed to other software through a well-defined set of services. To implement these services, and thus communicate with other software, the new application will use WCF.

~Image~

Addressing the Problem
The foundation for new Windows-based applications is the .NET Framework. Accordingly, WCF is implemented primarily as a set of classes on top of the .NET Framework CLR. Because it extends their familiar environment, WCF enables developers who create object-oriented applications using the .NET Framework today to also build service-oriented applications in a familiar way.

~Image~

Interoperability with Applications Built on Other Technologies
Because WCF’s fundamental communication mechanism is SOAP-based Web services, WCF-based applications can communicate with other software running in a variety of contexts. An application built on WCF can interact with all of the following:

1. WCF-based applications running in a different process on the same Windows machine.
2. WCF-based applications running on another Windows machine.
3. Applications built on other technologies, such as J2EE application servers, that support standard Web services. These applications can be running on Windows machines or on machines running other operating systems.



Sunday, July 15, 2007

Windows Presentation Foundation (WPF)

  1. To keep up with increasing expectations of users, the technology used to create user interfaces must also advance.

    The goal of Windows Presentation Foundation (WPF) is to provide these advances for Windows. Included in version 3.0 of the Microsoft .NET Framework, WPF allows building interfaces that incorporate documents, media, two- and three-dimensional graphics, animations, Web-like characteristics, and much more.

    A Unified Platform for Modern User Interfaces
    In a pre-WPF world, creating a Windows user interface like the one described earlier would require using several different technologies. The table below summarizes the situation.

    ~Table~

    The Ability for Developers and Designers to Work Together
    The way the two disciplines interact today is problematic. Most commonly, a designer uses a graphical tool to create static images of the screen layouts that an application should display. He then gives these images to the developer, whose job is to create the code that makes them real. Something that's easy for a designer to draw, however, might be difficult or impossible for a developer to implement. Technology limitations, schedule pressures, lack of skill, misunderstandings, or simple disagreement might prevent the developer from fully realizing the designer's vision. What's needed is a better way for members of these two interdependent disciplines to work together without compromising the quality of the interface.
    To allow this, WPF introduces the eXtensible Application Markup Language (XAML). XAML defines a set of XML elements such as Button, TextBox, Label, and many more to define exactly how a user interface looks. XAML elements typically have attributes as well, allowing various options to be set. For example, this simple XAML snippet creates a red button containing the word "No":



    A Common Technology for Windows and Web Browser User Interfaces

    Creating effective user interfaces for Windows applications is important. Yet creating effective interfaces for Web-based applications is at least as important. By definition, these interfaces are provided by a Web browser, and the simplest approach is just to let the browser passively display whatever HTML it receives. More responsive browser interfaces provide logic running in JavaScript, perhaps using asynchronous JavaScript and XML (AJAX). The interface may even support animations, video, and more using Adobe's Flash Player or some other technology. Sometimes known as rich Internet applications, Web software that provides this kind of full-featured interface can significantly improve the user's experience. It can also add substantial business value by making a Web application more attractive to users.

    The Technology of Windows Presentation Foundation

    Application Model
    At its root, every application inherits from WPF's standard Application class. This class provides common services that are useful to every application. These include holding state that needs to be available to the entire application and providing standard methods such as Run, which starts the application, and Shutdown, which terminates it.


    An Application object can be created with either XAML, via the Application element, or code, using the Application class. (This is true for virtually everything in WPF, but for simplicity, this paper always uses the XAML option.) Here's a simple XAML illustration

    . . .

    Layout and Controls
    Like any user interface technology, WPF provides a large set of controls, and developers are free to create custom controls as well. The standard set includes Button, Label, TextBox, ListBox, Menu, Slider, and other traditional atoms of user interface design. More complex controls are also provided, such as SpellCheck, PasswordBox, controls for working with ink (as with a Tablet PC), and more.

    As usual in a graphical interface, events generated by the user, such as mouse movements and key presses, can be caught and handled by the controls in a WPF application. While controls and other user interface elements can be fully specified using XAML, events must be handled in code. For example, here's a XAML definition of a simple Button on a Canvas:



    and the code

    namespace Example {
    public partial class CodeForCanvas : Canvas {
    void Button_Click(object sender, RoutedEventArgs e) {
    Button btn = e.Source as Button;
    btn.Background = Brushes.Purple;
    }
    }
    }

    The namespace and class name match that specified in the Canvas tag just shown. The class CodeForCanvas inherits from the base Canvas class provided by WPF, and it's defined as a partial class. Partial classes were a new addition in version 2.0 of the .NET Framework, and they allow combining code defined separately into a single class. In this case, the XAML-defined Canvas generates a partial class that gets combined with the partial class shown here. The result is a complete class capable of both displaying a canvas with a button and handling its event.


    Styles and Templates
    Using XAML's Style element, the creator of a WPF application can define one or more aspects of how something should look, then apply that style over and over. For example, a style named ButtonStyle might be defined like this:



    Any Button defined using this style would be given a red background and use a font size of 16. For example:



    Other Technologies are

    Text
    Documents
    Images
    Video and Audio
    Two-Dimensional Graphics
    Three-Dimensional Graphics
    Transformation and Effects
    Animation
    User Interface Automation

Thursday, July 12, 2007

.net Framework 3.0

Microsoft is again back with a new version of .net framework. This time its 3.0.
.net Framework 3.0 is much more than just a glossy wrapper on version 2.0.

The following diagram explains about the architectural overview of .net framework 3.0





Its very clear from the above diagram that the following new technology has been introduced in the framework.

WPF -- Windows Presentation Foundation
WCF -- Windows Communication Foundation
WF -- Windows Workflow Foundation
WCS -- Windows CardSpace


Seems to be new Abbreviation to learn like CTS/CLS/CLR.
I am sure that you will face questions like what is WPF/WCF...etc? in your next interview. So be prepared.

So here is the interview Answers for them. But do go through some more details as you know some time answers like "CTS is Common Type System" will not work. Read in detail to avoid being a sandwich when grilled by interviewer.



What is Windows Presentation Foundation (WPF)?
Windows Presentation Foundation (WPF) is the next-generation presentation sub-system for Windows. It provides developers and designers with a unified programming model for building rich Windows smart client user experiences that incorporate UI, media, and documents.

What is Windows Communication Foundation (WCF)?
The Windows Communication Foundation (previously codenamed "Indigo") is Microsoft's unified framework for building secure, reliable, transacted, and interoperable distributed applications.

What is Windows Workflow Foundation (WF)?
Windows Workflow Foundation (WF) is the programming model, engine and tools for quickly building workflow enabled applications. WF radically enhances a developer’s ability to model and support business processes.

What is Windows CardSpace (WCS, formerly “InfoCard”)?
Windows CardSpace enables users to provide their digital identities in a familiar, secure and easy way. In the physical world we use business cards, credit cards and membership cards. Online with CardSpace we use a variety of virtual cards to identify ourselves, each retrieving data from an identity provider. Don't struggle with usernames and passwords, just choose an information card!

I will be covering each of them in separate articles. So wait....for something usefull to come.