Touchstone Re 2023 API Reference
CreateExposureSet Method (DataSourceManagementServiceClient)
Example 


Air.Services.Proxy Assembly > (Global) Namespace > DataSourceManagementServiceClient Class : CreateExposureSet Method
Contains a CreateExposureSetRequest that identifies the Name of the Exposure Set that you want to create, along with the associated Touchstone-generated Data Source Sequential Identifier (SID), Business Unit SID and SQL Instance SID.
Creates a new Touchstone® Exposure Set.

An Exposure Set contains a discrete set of related Exposure data that includes the following information:

Syntax
Public Function CreateExposureSet( _
   ByVal request As CreateExposureSetRequest _
) As CreateExposureSetResponse
Dim instance As DataSourceManagementServiceClient
Dim request As CreateExposureSetRequest
Dim value As CreateExposureSetResponse
 
value = instance.CreateExposureSet(request)

Parameters

request
Contains a CreateExposureSetRequest that identifies the Name of the Exposure Set that you want to create, along with the associated Touchstone-generated Data Source Sequential Identifier (SID), Business Unit SID and SQL Instance SID.

Return Value

A CreateExposureSetResponse containing the Exposure Set SID, which uniquely identifies the Exposure Set that you have created.
Remarks
To find the Business Unit SID to pass into this method, call the GetBusinessUnits() method.

To find the SQL Instance SID to pass into this method, call the GetSqlInstances() method.

To find the Data Source SID to pass into this method, call the GetDataSources() method.

Example
The following example shows how to create a Touchstone Exposure Set using the CreateExposureSet() method:
using System;
using AIR.Services.Common.Data;
using AIR.Services.DataSourceManagement.Api;
            
class SnippetCreateExposureSetRequest
{
    private static void CreateExposureSet(int businessUnitSid, int sqlInstanceSid, int dataSourceSid, string exposureSetName)
    {
        DataSourceManagementServiceClient dsClient = new DataSourceManagementServiceClient();
        CreateExposureSetRequest request = new CreateExposureSetRequest();
        request.BusinessUnitSid = businessUnitSid;
        request.SqlInstanceSid = sqlInstanceSid;
        request.Name = exposureSetName;
        request.DataSourceSid = dataSourceSid;
        CreateExposureSetResponse response = dsClient.CreateExposureSet(request);
        if (response.Status.Code == StatusCode.Success)
        {
            Console.WriteLine("Exposure Set " + request.Name + " created with SID: " + response.ExposureSetSid);
        }
    }
}
Requirements

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

See Also

Reference

DataSourceManagementServiceClient Class
DataSourceManagementServiceClient Members