- Extension ID
- What's new?
- Description
- Supported REST client libraries
- Function Point, Quality and Sizing support
- CAST AIP compatibility
- Supported DBMS servers
- Prerequisites
- Dependencies with other extensions
- Download and installation instructions
- Packaging, delivering and analyzing your source code
- What results can you expect?
Extension ID
com.castsoftware.dotnet.service
What's new?
See REST service call for .NET - 1.0 - Release Notes for more information.
Description
This extension provides support for some web services calls from C#.
Supported REST client libraries
Native |
|
---|---|
Third-party |
|
- 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
Function Points (transactions) | Quality and Sizing |
---|---|
CAST AIP release | Supported |
---|---|
8.3.x |
Supported DBMS servers
This extension is compatible with the following DBMS servers:
CAST AIP release | CSS | Oracle | Microsoft |
---|---|---|---|
All supported releases |
Prerequisites
Installation of any compatible release of CAST AIP (see table above) |
Dependencies with other extensions
The REST Service Calls for .NET extension requires that ≥ 1.3.4-funcrel or ≥ 1.4.1-funcrel of the .NET Analyzer is also installed and used in order to ensure the most complete set of results. This dependency with the .NET Analyzer is not automatically handled when downloading the REST Service Calls for .NET extension via CAST Extension Downloader, CAST Server Manager or AIP Console, therefore you must ensure that the .NET Analyzer is downloaded and installed before starting an analysis.
Download and installation instructions
Please see:
The latest release status of this extension can be seen when downloading it from the CAST Extend server.
Packaging, delivering and analyzing your source code
Package your .NET code as described in .NET - Prepare and deliver the source code - the REST Service Calls for .NET extension will be run when you perform the analysis.
What results can you expect?
Features
This extension analyzes web service calls made from C# code through classic fluent APIs. For example with System.Net.Http.HttpClient:
using System; using System.Net.Http; class Main { void main() { var httpClient = new HttpClient(); HttpRequestMessage request = new HttpRequestMessage(HttpMethod.Get,"hello/world"); httpClient.SendAsync(request); } }
Refit
Refit provides the means to call web services through interfaces with attributes. Therefore, analyzing:
using System.Threading.Tasks; using Refit; public interface IGitHubApi { [Get("/users/{user}")] Task<string> GetUser(string user); }
will create:
Objects
The following objects are displayed in CAST Enlighten:
Icon | Description |
---|---|
Dotnet Delete Resource Service | |
Dotnet Get Resource Service | |
Dotnet Post Resource Service | |
Dotnet Put Resource Service | |
Dotnet Patch Resource Service |
Rules
None.
Limitations
- When the code uses a custom URL builder, we cannot evaluate the URL.
- Configuration files are not taken into account