Imports all Custom Frequency Sets into Touchstone®
Detailed Loss Analyses for a given SID within a specific
Business Unit and
SQL Server Instance.
Touchstone clients need a separate license for Model Builder with the Custom Event Frequency and Custom Vulnerability features in order to import custom catalogs using the Loss Analysis API.
The custom event frequency feature is applicable only to AIR models; it cannot be run with custom models created by the user. This feature does not apply for the Deterministic Event sets.
Parameters
- request
- Contains a GetCustomFrequencySetsRequest that identifies the Touchstone-generated Business Unit Sequential Identifier, SQL Instance SID, and SID associated with the list of the Custom Frequency Sets that you want to import.
Return Value
A
GetCustomFrequencySetsResponse containing a
list of Custom Frequency Sets for the specified Project within the specified SQL Server Instance and Business Unit.
The following example shows how to import a list of all custom frequency sets for each model into Touchstone for a given SID within specific Business Unit and SQL Server Instance using the
GetCustomFrequencySets()
method:
using AIR.Services.Common.Data;
using AIR.Services.LossAnalysis.Api;
using System;
class SnippetGetCustomFrequencySetsRequest
{
private static void GetCustomFrequencySets(int businessUnitSid, int sqlInstanceSid)
{
LossAnalysisServiceClient client = new LossAnalysisServiceClient();
GetCustomFrequencySetsRequest request = new GetCustomFrequencySetsRequest();
request.BusinessUnitSid = businessUnitSid;
request.SqlInstanceSid = sqlInstanceSid;
GetCustomFrequencySetsResponse response = client.GetCustomFrequencySets(request);
if (response.Status.Code == StatusCode.Success)
{
foreach (var es in response.CustomFrequencySets)
{
Console.WriteLine("SID: " + es.Sid);
Console.WriteLine("Name: " + es.CustomFrequencyName);
Console.WriteLine("Model Code: " + es.ModelCode);
}
}
}
}
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2