Dela via


Modeling the Application

Creating models in Visual Studio Ultimate helps you ensure that your application meets its users' needs. You can create models at different levels of detail and relate them to one another, to tests, and to your development plan. You can create and develop models throughout the application lifecycle as part of the development process. For more information, see:

To add capabilities to this release, download and install the Visual Studio 2010 Microsoft Visual Studio 2010 Visualization and Modeling Feature Pack.

Activities Supported by Models

Activity

Understand the users' needs: Clarify user stories, business rules, and other requirements and help ensure their consistency by drawing activity, class and other UML diagrams:

Visualize the code: See a visual representation of the code by generating dependency graphs and sequence diagrams. View the objects, settings, and relationships in your databases by creating an offline representation of those databases:

Define the architecture: Model the large-scale structure of the system and the design patterns by drawing UML component, class, and sequence diagrams. Define and enforce constraints on the dependencies between components of your code by creating layer diagrams.

Generate or configure parts of your application from UML or domain-specific languages and make your design more responsive to requirements changes and easily variable across a product line:

Validate your system with the requirements and intended design: Define acceptance tests or system tests based on the requirements models. This creates a strong relationship between the tests and your users' requirements and helps you update the system more easily when the requirements change.

Share models, diagrams, and graphs using Team Foundation version control: Put modeling project and diagram files, dependency graphs, and Architecture Explorer queries under Team Foundation version control. When you have multiple users who work with these items under Team Foundation version control, use these guidelines to help you avoid version control issues.

Customize the models and diagrams: Adapt models more closely to how your project uses them by defining additional properties for UML elements, validation constraints to make sure that your models conform to your business rules, and additional menu commands and toolbox items. You can also create your own domain-specific languages.

Types of Models and Their Uses

Model type and typical uses

UML model

A UML model includes several views, including class, component, use case, activity, and sequence diagrams. You can customize UML to suit your application domain. For example, you can attach tags, additional information, and constraints to the model elements. You can also define tools that operate on the models. For more information, see Developing Models for Software Design.

Typical uses:

  • Describe requirements and design. UML can be quickly applied to the development of any application. For more information, see Using Models within the Development Process.

  • Generate or configure tests or parts of an application. Some work is required to customize the notation and develop the generation templates or configurable application. For more information, see Generating and Configuring Your Application from Models.

  • For general description and for code generation or configuration in smaller projects.

Domain-specific language (DSL)

A DSL is a notation that you design for a specific purpose. In Visual Studio it is usually graphical. For more information, see Visualization and Modeling SDK - Domain-Specific Languages.

Typical uses:

  • Generate or configure parts of the application. Work is required to develop the notation and tools. The result can be a better fit to your domain than a UML customization.

  • For large projects or in product lines where the investment in developing the DSL and its tools is returned by its use in more than one project.

Layer diagram

A layer diagram lets you define the structure of an application as a set of layers or blocks with explicit dependencies. You can also validate code against the layer diagram on every check-in. For more information, see Layer Diagrams: Guidelines.

Typical uses:

Dependency or directed graph

Dependency and directed graphs let you inspect large and complex sets of dependencies or other relationships. You can generate graphs of the structure of your code. You can also write tools that create graphs from a wide variety of other sources. For more information, see How to: Generate Dependency Graphs for .NET Code.

Typical uses:

  • Analyze program code in preparation to update it, to help you understand its structure and estimate the cost of the proposed changes.

  • Analyze other large networks such as Web sites, databases, and so on.

Code-based sequence diagram

Sequence diagrams that you can generate from .NET code help you visualize how the code implements a method. For more information, see How to: Explore Code with Sequence Diagrams.

Typical uses:

  • Understand and analyze program code.

External Resources

Category

Links

Videos

link to videoChannel 9: Doug Seven: Code Understanding and System Design with Visual Studio 2010

link to videoChannel 9: UML with Visual Studio Ultimate

link to videoMSDN How Do I Series: UML Tools and Extensibility

Forums

Blogs

Technical Articles and Journals

The Architecture Journal - Issue 23: Architecture Modeling and Processes

Other Sites

MSDN Architecture Center

See Also

Concepts

Scenario Overview: Change Your Design Using Visualization and Modeling Tools

What's New for Application Lifecycle Management in Visual Studio 2010

Visual Studio Application Lifecycle Management