Inside VSTS

Visual Studio 2010: Introduction To The New Architecture Tools

Mickey provides an introduction to the new architecture tools in Visual Studio 2010 Ultimate.

TAG: Mickey gives you a introduction to the new architecture tools in Visual Studio 2010 Ultimate Visual Studio 2010 - Introduction To The New Architecture Tools

The architecture tools in Visual Studio 2010 have undergone a radical transformation. Support for Unified Modeling Language 2.1.1 (UML) diagrams has been added, as well as new tools and diagrams to help you understand your application, such as the Architecture Explorer and Dependency Graphs. In this column we are going to provide a brief overview of new functionality in Visual Studio 2010 that will be of interest to software architects. Future columns will delve into each of these individually in more detail.

To create the following UML diagrams, as well as to use the Architecture Explorer, requires Visual Studio 2010 Ultimate. Users of Visual Studio 2010 Premium have the ability to read diagrams created in Visual Studio 2010 Ultimate.

UML Diagrams in Visual Studio 2010
Out of the box, Visual Studio 2010 supports the following UML diagrams:
  • Use Case Diagrams
  • Activity Diagrams
  • Sequence Diagrams
  • Component Diagrams
  • Class Diagrams

A use case diagram provides a summary of who is using the application, and how they plan on using it. It is used to provide a view into how the application will be used and the actions that can take place in the system. Figure 1 shows an example of a use case diagram in Visual Studio 2010.


[Click on image for larger view.]
Figure 1.A use case diagram in Visual Studio 2010.

Once you have developed your use case diagrams, you will want to break them down into activity diagrams. An activity diagram is used to show a software process or business activity as a workflow through a series of actions. Figure 2 shows an example of an activity diagram in Visual Studio 2010.


[Click on image for larger view.]
Figure 2.An activity diagram in Visual Studio 2010.

Sequence diagrams are used to show interactions between different objects in the software system. Usually these interactions take place as a series of messages exchanged between the different objects. Figure 3 shows an example of a sequence diagram in Visual Studio 2010.


[Click on image for larger view.]
Figure 3.An example of a sequence diagram.

Once you have created your use case, activity and sequence diagrams, you are ready to visualize the different components that make up your software system. Component diagrams enable you to do just that, by laying out the different components in your system, and how they interact. Figure 4 shows an example of a component diagram in Visual Studio 2010.


[Click on image for larger view.]
Figure 4.A Visual Studio 2010 component diagram.

Class diagrams (also referred to as logical class diagrams) are used to describe the different objects in the application being developed. It does this without any reference to how the objects are implemented, allowing the diagram to be used regardless of the underlying code base used to develop the system. Figure 5 shows an example of a class diagram.


[Click on image for larger view.]
Figure 5.A class diagram is used to describe objects in the application.
Other Architecture Tools in Visual Studio 2010

In addition to UML support, Visual Studio 2010 also provides extra tools to help architects and other project team members understand the system under development. These tools include:

  • Layer Diagrams
  • The Architecture Explorer
  • Dependency Graphs

Layer diagrams are a new type of diagram that allow you to describe the "logical" architecture of your application. Your code can be organized into different "layers", allowing a better understanding of what objects perform what tasks. Layer diagrams can also be incorporated into the automated build process, allowing you to ensure that no architectural constraints have been violated. Figure 6 shows an example of a layer diagram.


[Click on image for larger view.]
Figure 6.New to Visual Studio 2010 is the layer diagram, which shows the logical architecture of an application.

The Architecture Explorer is a tool available in Visual Studio 2010 Ultimate that allows you to drill down into an existing code base, or even into compiled managed code, to gain a better understanding of what the code is trying to accomplish. Figure 7 shows an example of the Architecture Explorer.


[Click on image for larger view.]
Figure 7.The powerful Architecture Explorer tool is only available in Visual Studio 2010 Ultimate.

The Architecture Explorer can be combined with dependency graphs to make it easy to understand your code base. Dependency graphs are used to show the relationships between different objects and areas of code. Information discovered using the Architecture Explorer can be easily visualized using dependency graphs. Figure 8 shows an example of dependency graph created using information from the Architecture Explorer.


[Click on image for larger view.]
Figure 8.Use the dependency graph to view relationships among different objects and areas of code.
Conclusion
Visual Studio 2010 Ultimate contains several new tools of interest to software architects. Its support of UML 2.1.1 diagrams, as well as the new tools in the Architecture Explorer and dependency graphs, provides needed functionality that allows architects to design the applications they want, and help developers better understand the software that needs to be built.

About the Author

Mickey Gousset spends his days as a principal consultant for Infront Consulting Group. Gousset is lead author of "Professional Application Lifecycle Management with Visual Studio 2012" (Wrox, 2012) and frequents the speaker circuit singing the praises of ALM and DevOps. He also blogs at ALM Rocks!. Gousset is one of the original Team System/ALM MVPs and has held the award since 2005.

comments powered by Disqus

Featured

  • Creating Reactive Applications in .NET

    In modern applications, data is being retrieved in asynchronous, real-time streams, as traditional pull requests where the clients asks for data from the server are becoming a thing of the past.

  • AI for GitHub Collaboration? Maybe Not So Much

    No doubt GitHub Copilot has been a boon for developers, but AI might not be the best tool for collaboration, according to developers weighing in on a recent social media post from the GitHub team.

  • Visual Studio 2022 Getting VS Code 'Command Palette' Equivalent

    As any Visual Studio Code user knows, the editor's command palette is a powerful tool for getting things done quickly, without having to navigate through menus and dialogs. Now, we learn how an equivalent is coming for Microsoft's flagship Visual Studio IDE, invoked by the same familiar Ctrl+Shift+P keyboard shortcut.

  • .NET 9 Preview 3: 'I've Been Waiting 9 Years for This API!'

    Microsoft's third preview of .NET 9 sees a lot of minor tweaks and fixes with no earth-shaking new functionality, but little things can be important to individual developers.

  • Data Anomaly Detection Using a Neural Autoencoder with C#

    Dr. James McCaffrey of Microsoft Research tackles the process of examining a set of source data to find data items that are different in some way from the majority of the source items.

Subscribe on YouTube