// This is an automatically generated code sample. 
// To make this code sample work in your Oracle Cloud tenancy, 
// please replace the values for any parameters whose current values do not fit
// your use case (such as resource IDs, strings containing ‘EXAMPLE’ or ‘unique_id’, and 
// boolean, number, and enum parameters with values not fitting your use case).

using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using Oci.DatasafeService;
using Oci.Common;
using Oci.Common.Auth;

namespace Oci.Sdk.DotNet.Example.Datasafe
{
    public class ListMaskingColumnsExample
    {
        public static async Task Main()
        {
            // Create a request and dependent object(s).
			var listMaskingColumnsRequest = new Oci.DatasafeService.Requests.ListMaskingColumnsRequest
			{
				MaskingPolicyId = "ocid1.test.oc1..<unique_ID>EXAMPLE-maskingPolicyId-Value",
				Limit = 158,
				Page = "EXAMPLE-page-Value",
				SortOrder = Oci.DatasafeService.Requests.ListMaskingColumnsRequest.SortOrderEnum.Asc,
				SortBy = Oci.DatasafeService.Requests.ListMaskingColumnsRequest.SortByEnum.ObjectName,
				MaskingColumnLifecycleState = Oci.DatasafeService.Models.MaskingColumnLifecycleState.Active,
				DataType = new List<Oci.DatasafeService.Requests.ListMaskingColumnsRequest.DataTypeEnum>
				{
					Oci.DatasafeService.Requests.ListMaskingColumnsRequest.DataTypeEnum.Numeric
				},
				SchemaName = new List<string>
				{
					"EXAMPLE--Value"
				},
				ObjectName = new List<string>
				{
					"EXAMPLE--Value"
				},
				ColumnName = new List<string>
				{
					"EXAMPLE--Value"
				},
				ObjectType = new List<Oci.DatasafeService.Requests.ListMaskingColumnsRequest.ObjectTypeEnum>
				{
					Oci.DatasafeService.Requests.ListMaskingColumnsRequest.ObjectTypeEnum.Table
				},
				MaskingColumnGroup = new List<string>
				{
					"EXAMPLE--Value"
				},
				SensitiveTypeId = "ocid1.test.oc1..<unique_ID>EXAMPLE-sensitiveTypeId-Value",
				IsMaskingEnabled = false,
				IsSeedRequired = false,
				TimeCreatedGreaterThanOrEqualTo = DateTime.Parse("01/10/2045 15:44:41"),
				TimeCreatedLessThan = DateTime.Parse("04/18/2024 03:01:11"),
				TimeUpdatedGreaterThanOrEqualTo = DateTime.Parse("04/02/2036 10:01:16"),
				TimeUpdatedLessThan = DateTime.Parse("01/29/2024 14:22:21"),
				OpcRequestId = "EJ7W44VICQVLAVUH4HVL<unique_ID>"
			};

            // Create a default authentication provider that uses the DEFAULT
            // profile in the configuration file.
            // Refer to <see href="https://docs.cloud.oracle.com/en-us/iaas/Content/API/Concepts/sdkconfig.htm#SDK_and_CLI_Configuration_File>the public documentation</see> on how to prepare a configuration file. 
            var provider = new ConfigFileAuthenticationDetailsProvider("DEFAULT");
            try
            {
                // Create a service client and send the request.
				using (var client = new DataSafeClient(provider, new ClientConfiguration()))
				{
					var response = await client.ListMaskingColumns(listMaskingColumnsRequest);
					// Retrieve value from the response.
					var itemsValue = response.MaskingColumnCollection.Items;
				}
            }
            catch (Exception e)
            {
                Console.WriteLine($"ListMaskingColumns Failed with {e.Message}");
                throw e;
            }
        }

    }
}