The WPF extension releases 1.0 - 1.4 are deprecated and no new development will be actioned. All new features and functionality for the support of WPF are now handled instead by the .NET XAML extension using the com.castsoftware.wpf extension ID. Please see the section of documentation entitled Existing extensions for WPF and Silverlight for more information about the .NET XAML extension and the impacts of moving to it.
Summary: This document provides information about the extension providing WPF (Windows Presentation Foundation) support for C# and VB.NET.
This extension provides support for WPF (Windows Presentation Foundation). The calculation of Automated Function Points for your .NET analyses will be supplemented through the creation of new objects and links specific to the WPF framework that will link back to objects/links produced by the base .NET analyzer.
In what situation should you install this extension?
If your .NET application contains WPF (Windows Presentation Foundation) source code and you want to view these object types and their links, then you should install this extension.
The extension is now shipped with a set of CAST Transaction Configuration Center Entry Points, specifically related to WPF. Please see CAST Transaction Configuration Center (TCC) Entry Points below for more information about this.
WPF framework support
The following WPF frameworks are supported by this extension:
|All versions up to 4.5|
- Function Points (transactions): a green tick indicates that OMG Function Point counting and Transaction Risk Index are supported
- Quality and Sizing: a green tick indicates that CAST can measure size and that a minimum set of Quality Rules exist
|Quality and Sizing|
CAST AIP release
|8.3.x||C# and VB.NET|
|8.2.x||C# and VB.NET|
Supported DBMS servers
This extension is compatible with the following DBMS servers:
|Microsoft SQL Server|
Download and installation instructions
Include the extension using the interface in AIP Console:
There is nothing further to do. Follow the instructions below to run a new analysis/snapshot to generate new results:
- Advanced onboarding - run and validate the initial analysis
- Advanced onboarding - snapshot generation and validation
What results can you expect?
Once the analysis/snapshot generation has completed, you can view the results in the normal manner. The following objects and links will be displayed in CAST Enlighten:
All objects are represented under the File browser > Xaml Source file folders in CAST Enlighten as either WPF Custom Controls, or WPF Controls:
|WPF Custom Control|
Note that if the Name Attribute of an object is present, then it will be used to display that object in CAST Enlighten. For example:
|Name not present||Name present|
The following objects are detected:
|XAML Control||call||Action Event method implemented in source file|
|XAML Control||relyOn||Set and get accessors of Property implemented in source file|
|XAML Control||relyOn||XAML Control which is used|
|XAML Custom Control||relyOn|
XAML page that contains its definition
|XAML Custom Control||relyOn||Defined Class|
|XAML Custom Control||AccessExec||Corresponding Property|
|XAML Custom Control||AccessExec||Corresponding Event handler function|
|XAML Source File||relyOn||Referred Class|
In this section we list the most significant functional limitations that may affect the analysis of applications using WPF:
- Binding in code is not supported - see https://msdn.microsoft.com/en-us/library/ms742863(v=vs.110).aspx?cs-save-lang=1&cs-lang=csharp#code-snippet-1 for an example
Binding links are not handled correctly when the same binding target exists in different classes
- The direction of the data flow (Binding.Mode properties such as OneWay, TwoWay and OneWayToSource) is not supported - see https://msdn.microsoft.com/en-us/library/ms752347(v=vs.110).aspx#direction_of_data_flow for an example
- The RelativeSource property (Gets or sets the binding source by specifying its location relative to the position of the binding target) is not supported - see https://msdn.microsoft.com/en-us/library/system.windows.data.binding.relativesource(v=vs.110).aspx for an example
- Some XAML control objects which are visible in CAST Enlighten may not be seen in the CAST Engineering Dashboard.
- Links between XAML Control objects and code embedded in XAML are not supported.