/// <summary>Snippet for GetSystemPolicyAsync</summary> public async Task GetSystemPolicyAsync() { // Snippet: GetSystemPolicyAsync(string, CallSettings) // Additional: GetSystemPolicyAsync(string, CancellationToken) // Create client SystemPolicyV1Beta1Client systemPolicyV1Beta1Client = await SystemPolicyV1Beta1Client.CreateAsync(); // Initialize request argument(s) string name = "projects/[PROJECT]/policy"; // Make the request Policy response = await systemPolicyV1Beta1Client.GetSystemPolicyAsync(name); // End snippet }
/// <summary>Snippet for GetSystemPolicyAsync</summary> public async Task GetSystemPolicyResourceNamesAsync() { // Snippet: GetSystemPolicyAsync(PolicyName, CallSettings) // Additional: GetSystemPolicyAsync(PolicyName, CancellationToken) // Create client SystemPolicyV1Beta1Client systemPolicyV1Beta1Client = await SystemPolicyV1Beta1Client.CreateAsync(); // Initialize request argument(s) PolicyName name = PolicyName.FromProject("[PROJECT]"); // Make the request Policy response = await systemPolicyV1Beta1Client.GetSystemPolicyAsync(name); // End snippet }
/// <summary>Snippet for GetSystemPolicyAsync</summary> public async Task GetSystemPolicyRequestObjectAsync() { // Snippet: GetSystemPolicyAsync(GetSystemPolicyRequest, CallSettings) // Additional: GetSystemPolicyAsync(GetSystemPolicyRequest, CancellationToken) // Create client SystemPolicyV1Beta1Client systemPolicyV1Beta1Client = await SystemPolicyV1Beta1Client.CreateAsync(); // Initialize request argument(s) GetSystemPolicyRequest request = new GetSystemPolicyRequest { PolicyName = PolicyName.FromProject("[PROJECT]"), }; // Make the request Policy response = await systemPolicyV1Beta1Client.GetSystemPolicyAsync(request); // End snippet }