You are previewing Building Enterprise Applications with Windows® Presentation Foundation and the Model View ViewModel Pattern.
O'Reilly logo
Building Enterprise Applications with Windows® Presentation Foundation and the Model View ViewModel Pattern

Book Description

Take advantage of Windows® Presentation Foundation and the Model View ViewModel design pattern to build rich client applications for the enterprise. With this hands-on guide, you'll master the techniques to bind data to your WPF user interfaces by constructing an example application through the course of the book.

Table of Contents

  1. Building Enterprise Applications with Windows® Presentation Foundation and the Model View ViewModel Pattern
    1. SPECIAL OFFER: Upgrade this ebook with O’Reilly
    2. A Note Regarding Supplemental Files
    3. Introduction
      1. Who Should Read this Book
        1. Assumptions
      2. Organization of This Book
        1. Finding Your Best Starting Point in This Book
    4. Conventions and Features in This Book
      1. System Requirements
        1. Code Samples
        2. Installing the Code Samples
        3. Using the Code Samples
    5. Acknowledgments
    6. Errata and Book Support
      1. We Want to Hear from You
      2. Stay in Touch
    7. 1. Introduction to Model View ViewModel and Line of Business Applications
      1. The Model View ViewModel Pattern
      2. Line of Business Applications
      3. Choosing the Right Technology
        1. Silverlight or WPF?
        2. Microsoft’s UI-Building Tools
          1. Expression Blend
          2. Microsoft Sketchflow
      4. Composition of a LOB User Interface
        1. The Menubar
        2. The Toolbar
        3. The Tooltip (and Its Abuse)
        4. Notifications and Alerts
        5. The Ribbon Bar
        6. General Style and Control Considerations
      5. Separation of Concerns
        1. Layers, Tiers, and Services
      6. Summary
    8. 2. Design Patterns
      1. An Overview of Design Patterns
        1. Classifying Design Patterns
          1. Creational Patterns
          2. Structural Patterns
          3. Behavioral Patterns
      2. UI Design Patterns
        1. The MVC Pattern
          1. Pros and Cons of the MVC Pattern
        2. The MVP Pattern
          1. Pros and Cons of the MVP Pattern
          2. Alternative Approaches to MVP
        3. The PM Pattern and MVVM
          1. MVVM Pros and Cons
      3. Advanced Design Patterns and Techniques
        1. The Inversion of Control Pattern
          1. Microsoft Unity
          2. Dependency Injection with Unity
          3. Service Locator with Unity
          4. The Managed Extensibility Framework
          5. Differences Between MEF and Unity
        2. DSLs: Writing Fluent Code
          1. Writing a Fluent Interface in C#
        3. Introduction to TDD
          1. A TDD Example
          2. Tools for Unit Testing
          3. Available Resources for TDD
      4. Summary
    9. 3. The Domain Model
      1. Introduction to Domain-Driven Design
        1. DDD Terminology
        2. Analyzing the CRM Domain
      2. Domain Entity and Data Transfer Object
      3. The POCO Object and the O/RM
      4. Development Approaches of a Domain
        1. Transaction Script
        2. Database-Driven Approach
        3. Domain-Driven Approach
      5. How To Create an Object In DDD
        1. Factory Patterns
      6. Domain Entities Validation
        1. Classic Validation
        2. Validation Using Attributes and Data Annotations
        3. Available Validation Frameworks
      7. Unit Test the Domain Model
      8. Sample Code: The CRM Domain Model
        1. The Person Context
        2. The Order Domain
      9. Summary
    10. 4. The Data Access Layer
      1. Introduction
      2. The Database and Stored Procedures
      3. Choosing an O/RM
        1. Microsoft Entity Framework
        2. NHibernate
        3. Other O/RMs for .NET
      4. The Unit of Work
        1. Lifecycle of a UoW
        2. Identify a Business Transaction
      5. The Repository Pattern
      6. Test-Driven Development: The Data Layer
      7. Building a Distributed Data Layer with RIA and WCF
      8. Sample Code: The CRM Data Access Layer
        1. A Flexible IUnitOfWork Interface
        2. Mapping the Domain Model Using Entity Framework
          1. Creating a Concrete DAL for Entity Framework
      9. Mapping the Domain Using NHibernate
        1. Getting the Tools
        2. The UnitOfWork and the ISession
          1. The Repository
      10. Summary
    11. 5. The Business Layer
      1. Introduction
      2. A Business Rule Is Not a Validation Rule
      3. Business Rules by Service
        1. The Facade Pattern
      4. Business Rules by Workflow with WF 4.0
        1. Different Ways of Running a Workflow
          1. WorkFlowInvoker
          2. Pros and Cons of the WorkflowInvoker
          3. WorkflowApplication and WCF
          4. AppFabric and the WCF Execution
          5. Pros and Cons of WorkflowApplication
      5. Third-Party Toolkits
        1. Technologies for the Data Validation
        2. Rule Engine and Business Rule Engine
          1. InRule for .NET
      6. Business Layer Considerations
        1. When Do I Need to Create a Business Layer?
        2. Bad BLL Habits
      7. Sample Code: The Business Service Layer
        1. Data Validation with the Enterprise Library 5.0
        2. A Generic Workflow Engine
        3. Service for Business Transactions
      8. Summary
    12. 6. The UI Layer with MVVM
      1. Introduction to the MVVM Pattern
      2. The View
        1. Blendability: A Dummy ViewModel
      3. The Model
      4. The Command in WPF and Silverlight
        1. A Workaround: An MVVM Command
        2. Re-evaluate ICommand Execution
      5. The ViewModel
        1. The INotifyPropertyChanged Interface
        2. The IDataErrorInfo Interface
      6. DataTemplate in WPF and Silverlight
        1. DataTemplate and MVVM
      7. WeakEvents and Messages
        1. The WeakEvent Pattern
        2. The EventAggregator Pattern
      8. Dialogs and Modal Pop-Ups
        1. Modal View in MVVM
          1. Modal Service
          2. A Mediator Approach
      9. Inversion of Control with MVVM
      10. Sample Code
        1. The Microsoft Office Ribbon and MVVM
      11. Summary
    13. 7. MVVM Frameworks and Toolkits
      1. MVVM Toolkits
        1. MVVM Light Toolkit, by Laurent Bugnion
        2. MEFedMVVM
        3. Cinch, by Sacha Barber
      2. MVVM and XAML Facilities
        1. Karl Shifflett’s Tools
          1. XAML Power Toys
          2. XAML Editor
          3. In the Box Tutorial (MVVM)
        2. Radical, by Mauro Servienti
      3. Composite UI Frameworks
        1. Microsoft Prism
          1. Calcium SDK
        2. Caliburn
    14. A. About the Author
    15. Index
    16. About the Author
    17. SPECIAL OFFER: Upgrade this ebook with O’Reilly