-
Notifications
You must be signed in to change notification settings - Fork 362
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Add SimulateSecurityHealthAnalyticsCustomModule API for testing…
… SHA custom module PiperOrigin-RevId: 574612611 Source-Link: googleapis/googleapis@c768e7a Source-Link: googleapis/googleapis-gen@e5502fc Copy-Tag: eyJwIjoiYXBpcy9Hb29nbGUuQ2xvdWQuU2VjdXJpdHlDZW50ZXIuVjEvLk93bEJvdC55YW1sIiwiaCI6ImU1NTAyZmMxN2VjZWFjYTFjMjM1MmZkMmE2MTRjNzZlYzYzZWY4ZTQifQ==
- Loading branch information
1 parent
5f54d64
commit bdb2a81
Showing
10 changed files
with
2,611 additions
and
721 deletions.
There are no files selected for viewing
46 changes: 46 additions & 0 deletions
46
...nippets/SecurityCenterClient.SimulateSecurityHealthAnalyticsCustomModuleAsyncSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
// Copyright 2023 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace GoogleCSharpSnippets | ||
{ | ||
// [START securitycenter_v1_generated_SecurityCenter_SimulateSecurityHealthAnalyticsCustomModule_async_flattened] | ||
using Google.Cloud.SecurityCenter.V1; | ||
using System.Threading.Tasks; | ||
|
||
public sealed partial class GeneratedSecurityCenterClientSnippets | ||
{ | ||
/// <summary>Snippet for SimulateSecurityHealthAnalyticsCustomModuleAsync</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public async Task SimulateSecurityHealthAnalyticsCustomModuleAsync() | ||
{ | ||
// Create client | ||
SecurityCenterClient securityCenterClient = await SecurityCenterClient.CreateAsync(); | ||
// Initialize request argument(s) | ||
string parent = ""; | ||
CustomConfig customConfig = new CustomConfig(); | ||
SimulateSecurityHealthAnalyticsCustomModuleRequest.Types.SimulatedResource resource = new SimulateSecurityHealthAnalyticsCustomModuleRequest.Types.SimulatedResource(); | ||
// Make the request | ||
SimulateSecurityHealthAnalyticsCustomModuleResponse response = await securityCenterClient.SimulateSecurityHealthAnalyticsCustomModuleAsync(parent, customConfig, resource); | ||
} | ||
} | ||
// [END securitycenter_v1_generated_SecurityCenter_SimulateSecurityHealthAnalyticsCustomModule_async_flattened] | ||
} |
49 changes: 49 additions & 0 deletions
49
...ityCenterClient.SimulateSecurityHealthAnalyticsCustomModuleRequestObjectAsyncSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
// Copyright 2023 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace GoogleCSharpSnippets | ||
{ | ||
// [START securitycenter_v1_generated_SecurityCenter_SimulateSecurityHealthAnalyticsCustomModule_async] | ||
using Google.Cloud.SecurityCenter.V1; | ||
using System.Threading.Tasks; | ||
|
||
public sealed partial class GeneratedSecurityCenterClientSnippets | ||
{ | ||
/// <summary>Snippet for SimulateSecurityHealthAnalyticsCustomModuleAsync</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public async Task SimulateSecurityHealthAnalyticsCustomModuleRequestObjectAsync() | ||
{ | ||
// Create client | ||
SecurityCenterClient securityCenterClient = await SecurityCenterClient.CreateAsync(); | ||
// Initialize request argument(s) | ||
SimulateSecurityHealthAnalyticsCustomModuleRequest request = new SimulateSecurityHealthAnalyticsCustomModuleRequest | ||
{ | ||
Parent = "", | ||
CustomConfig = new CustomConfig(), | ||
Resource = new SimulateSecurityHealthAnalyticsCustomModuleRequest.Types.SimulatedResource(), | ||
}; | ||
// Make the request | ||
SimulateSecurityHealthAnalyticsCustomModuleResponse response = await securityCenterClient.SimulateSecurityHealthAnalyticsCustomModuleAsync(request); | ||
} | ||
} | ||
// [END securitycenter_v1_generated_SecurityCenter_SimulateSecurityHealthAnalyticsCustomModule_async] | ||
} |
48 changes: 48 additions & 0 deletions
48
...SecurityCenterClient.SimulateSecurityHealthAnalyticsCustomModuleRequestObjectSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
// Copyright 2023 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace GoogleCSharpSnippets | ||
{ | ||
// [START securitycenter_v1_generated_SecurityCenter_SimulateSecurityHealthAnalyticsCustomModule_sync] | ||
using Google.Cloud.SecurityCenter.V1; | ||
|
||
public sealed partial class GeneratedSecurityCenterClientSnippets | ||
{ | ||
/// <summary>Snippet for SimulateSecurityHealthAnalyticsCustomModule</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public void SimulateSecurityHealthAnalyticsCustomModuleRequestObject() | ||
{ | ||
// Create client | ||
SecurityCenterClient securityCenterClient = SecurityCenterClient.Create(); | ||
// Initialize request argument(s) | ||
SimulateSecurityHealthAnalyticsCustomModuleRequest request = new SimulateSecurityHealthAnalyticsCustomModuleRequest | ||
{ | ||
Parent = "", | ||
CustomConfig = new CustomConfig(), | ||
Resource = new SimulateSecurityHealthAnalyticsCustomModuleRequest.Types.SimulatedResource(), | ||
}; | ||
// Make the request | ||
SimulateSecurityHealthAnalyticsCustomModuleResponse response = securityCenterClient.SimulateSecurityHealthAnalyticsCustomModule(request); | ||
} | ||
} | ||
// [END securitycenter_v1_generated_SecurityCenter_SimulateSecurityHealthAnalyticsCustomModule_sync] | ||
} |
45 changes: 45 additions & 0 deletions
45
...atedSnippets/SecurityCenterClient.SimulateSecurityHealthAnalyticsCustomModuleSnippet.g.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
// Copyright 2023 Google LLC | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// https://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
// Generated code. DO NOT EDIT! | ||
|
||
namespace GoogleCSharpSnippets | ||
{ | ||
// [START securitycenter_v1_generated_SecurityCenter_SimulateSecurityHealthAnalyticsCustomModule_sync_flattened] | ||
using Google.Cloud.SecurityCenter.V1; | ||
|
||
public sealed partial class GeneratedSecurityCenterClientSnippets | ||
{ | ||
/// <summary>Snippet for SimulateSecurityHealthAnalyticsCustomModule</summary> | ||
/// <remarks> | ||
/// This snippet has been automatically generated and should be regarded as a code template only. | ||
/// It will require modifications to work: | ||
/// - It may require correct/in-range values for request initialization. | ||
/// - It may require specifying regional endpoints when creating the service client as shown in | ||
/// https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint. | ||
/// </remarks> | ||
public void SimulateSecurityHealthAnalyticsCustomModule() | ||
{ | ||
// Create client | ||
SecurityCenterClient securityCenterClient = SecurityCenterClient.Create(); | ||
// Initialize request argument(s) | ||
string parent = ""; | ||
CustomConfig customConfig = new CustomConfig(); | ||
SimulateSecurityHealthAnalyticsCustomModuleRequest.Types.SimulatedResource resource = new SimulateSecurityHealthAnalyticsCustomModuleRequest.Types.SimulatedResource(); | ||
// Make the request | ||
SimulateSecurityHealthAnalyticsCustomModuleResponse response = securityCenterClient.SimulateSecurityHealthAnalyticsCustomModule(parent, customConfig, resource); | ||
} | ||
} | ||
// [END securitycenter_v1_generated_SecurityCenter_SimulateSecurityHealthAnalyticsCustomModule_sync_flattened] | ||
} |
Oops, something went wrong.