Skip to content

Commit

Permalink
feat: Updated the method signature of analyzeWorkloadMove for v1beta …
Browse files Browse the repository at this point in the history
…API to accept project as source. AnalyzeWorkloadMove now also returns information about org policy differences between the project and target folder

Committer: @ketanbshah
PiperOrigin-RevId: 461626403

Source-Link: googleapis/googleapis@6aee59c

Source-Link: googleapis/googleapis-gen@1e4553d
Copy-Tag: eyJwIjoiYXBpcy9Hb29nbGUuQ2xvdWQuQXNzdXJlZFdvcmtsb2Fkcy5WMUJldGExLy5Pd2xCb3QueWFtbCIsImgiOiIxZTQ1NTNkNjNlNzllZDI1M2RiMTE5NzRiYzZjNzQwNTY3YmNiMDNjIn0=
  • Loading branch information
gcf-owl-bot[bot] authored and jskeet committed Jul 19, 2022
1 parent 2b501e8 commit 31b0016
Show file tree
Hide file tree
Showing 18 changed files with 3,351 additions and 307 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
// Copyright 2022 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 Google.Cloud.AssuredWorkloads.V1Beta1.Snippets
{
// [START assuredworkloads_v1beta1_generated_AssuredWorkloadsService_AnalyzeWorkloadMove_async_flattened]
using Google.Cloud.AssuredWorkloads.V1Beta1;
using System.Threading.Tasks;

public sealed partial class GeneratedAssuredWorkloadsServiceClientSnippets
{
/// <summary>Snippet for AnalyzeWorkloadMoveAsync</summary>
/// <remarks>
/// This snippet has been automatically generated for illustrative purposes only.
/// It may require modifications to work in your environment.
/// </remarks>
public async Task AnalyzeWorkloadMoveAsync()
{
// Create client
AssuredWorkloadsServiceClient assuredWorkloadsServiceClient = await AssuredWorkloadsServiceClient.CreateAsync();
// Initialize request argument(s)
string project = "";
string target = "";
// Make the request
AnalyzeWorkloadMoveResponse response = await assuredWorkloadsServiceClient.AnalyzeWorkloadMoveAsync(project, target);
}
}
// [END assuredworkloads_v1beta1_generated_AssuredWorkloadsService_AnalyzeWorkloadMove_async_flattened]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
// Copyright 2022 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 Google.Cloud.AssuredWorkloads.V1Beta1.Snippets
{
// [START assuredworkloads_v1beta1_generated_AssuredWorkloadsService_AnalyzeWorkloadMove_async]
using Google.Cloud.AssuredWorkloads.V1Beta1;
using System.Threading.Tasks;

public sealed partial class GeneratedAssuredWorkloadsServiceClientSnippets
{
/// <summary>Snippet for AnalyzeWorkloadMoveAsync</summary>
/// <remarks>
/// This snippet has been automatically generated for illustrative purposes only.
/// It may require modifications to work in your environment.
/// </remarks>
public async Task AnalyzeWorkloadMoveRequestObjectAsync()
{
// Create client
AssuredWorkloadsServiceClient assuredWorkloadsServiceClient = await AssuredWorkloadsServiceClient.CreateAsync();
// Initialize request argument(s)
AnalyzeWorkloadMoveRequest request = new AnalyzeWorkloadMoveRequest
{
Source = "",
Target = "",
};
// Make the request
AnalyzeWorkloadMoveResponse response = await assuredWorkloadsServiceClient.AnalyzeWorkloadMoveAsync(request);
}
}
// [END assuredworkloads_v1beta1_generated_AssuredWorkloadsService_AnalyzeWorkloadMove_async]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
// Copyright 2022 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 Google.Cloud.AssuredWorkloads.V1Beta1.Snippets
{
// [START assuredworkloads_v1beta1_generated_AssuredWorkloadsService_AnalyzeWorkloadMove_sync]
using Google.Cloud.AssuredWorkloads.V1Beta1;

public sealed partial class GeneratedAssuredWorkloadsServiceClientSnippets
{
/// <summary>Snippet for AnalyzeWorkloadMove</summary>
/// <remarks>
/// This snippet has been automatically generated for illustrative purposes only.
/// It may require modifications to work in your environment.
/// </remarks>
public void AnalyzeWorkloadMoveRequestObject()
{
// Create client
AssuredWorkloadsServiceClient assuredWorkloadsServiceClient = AssuredWorkloadsServiceClient.Create();
// Initialize request argument(s)
AnalyzeWorkloadMoveRequest request = new AnalyzeWorkloadMoveRequest
{
Source = "",
Target = "",
};
// Make the request
AnalyzeWorkloadMoveResponse response = assuredWorkloadsServiceClient.AnalyzeWorkloadMove(request);
}
}
// [END assuredworkloads_v1beta1_generated_AssuredWorkloadsService_AnalyzeWorkloadMove_sync]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
// Copyright 2022 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 Google.Cloud.AssuredWorkloads.V1Beta1.Snippets
{
// [START assuredworkloads_v1beta1_generated_AssuredWorkloadsService_AnalyzeWorkloadMove_sync_flattened]
using Google.Cloud.AssuredWorkloads.V1Beta1;

public sealed partial class GeneratedAssuredWorkloadsServiceClientSnippets
{
/// <summary>Snippet for AnalyzeWorkloadMove</summary>
/// <remarks>
/// This snippet has been automatically generated for illustrative purposes only.
/// It may require modifications to work in your environment.
/// </remarks>
public void AnalyzeWorkloadMove()
{
// Create client
AssuredWorkloadsServiceClient assuredWorkloadsServiceClient = AssuredWorkloadsServiceClient.Create();
// Initialize request argument(s)
string project = "";
string target = "";
// Make the request
AnalyzeWorkloadMoveResponse response = assuredWorkloadsServiceClient.AnalyzeWorkloadMove(project, target);
}
}
// [END assuredworkloads_v1beta1_generated_AssuredWorkloadsService_AnalyzeWorkloadMove_sync_flattened]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
// Copyright 2022 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 Google.Cloud.AssuredWorkloads.V1Beta1.Snippets
{
// [START assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedResources_async]
using Google.Cloud.AssuredWorkloads.V1Beta1;
using System.Threading.Tasks;

public sealed partial class GeneratedAssuredWorkloadsServiceClientSnippets
{
/// <summary>Snippet for RestrictAllowedResourcesAsync</summary>
/// <remarks>
/// This snippet has been automatically generated for illustrative purposes only.
/// It may require modifications to work in your environment.
/// </remarks>
public async Task RestrictAllowedResourcesRequestObjectAsync()
{
// Create client
AssuredWorkloadsServiceClient assuredWorkloadsServiceClient = await AssuredWorkloadsServiceClient.CreateAsync();
// Initialize request argument(s)
RestrictAllowedResourcesRequest request = new RestrictAllowedResourcesRequest
{
Name = "",
RestrictionType = RestrictAllowedResourcesRequest.Types.RestrictionType.Unspecified,
};
// Make the request
RestrictAllowedResourcesResponse response = await assuredWorkloadsServiceClient.RestrictAllowedResourcesAsync(request);
}
}
// [END assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedResources_async]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
// Copyright 2022 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 Google.Cloud.AssuredWorkloads.V1Beta1.Snippets
{
// [START assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedResources_sync]
using Google.Cloud.AssuredWorkloads.V1Beta1;

public sealed partial class GeneratedAssuredWorkloadsServiceClientSnippets
{
/// <summary>Snippet for RestrictAllowedResources</summary>
/// <remarks>
/// This snippet has been automatically generated for illustrative purposes only.
/// It may require modifications to work in your environment.
/// </remarks>
public void RestrictAllowedResourcesRequestObject()
{
// Create client
AssuredWorkloadsServiceClient assuredWorkloadsServiceClient = AssuredWorkloadsServiceClient.Create();
// Initialize request argument(s)
RestrictAllowedResourcesRequest request = new RestrictAllowedResourcesRequest
{
Name = "",
RestrictionType = RestrictAllowedResourcesRequest.Types.RestrictionType.Unspecified,
};
// Make the request
RestrictAllowedResourcesResponse response = assuredWorkloadsServiceClient.RestrictAllowedResources(request);
}
}
// [END assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedResources_sync]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
// Copyright 2022 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 Google.Cloud.AssuredWorkloads.V1Beta1.Snippets
{
// [START assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedServices_async]
using Google.Cloud.AssuredWorkloads.V1Beta1;
using System.Threading.Tasks;

public sealed partial class GeneratedAssuredWorkloadsServiceClientSnippets
{
/// <summary>Snippet for RestrictAllowedServicesAsync</summary>
/// <remarks>
/// This snippet has been automatically generated for illustrative purposes only.
/// It may require modifications to work in your environment.
/// </remarks>
public async Task RestrictAllowedServicesRequestObjectAsync()
{
// Create client
AssuredWorkloadsServiceClient assuredWorkloadsServiceClient = await AssuredWorkloadsServiceClient.CreateAsync();
// Initialize request argument(s)
RestrictAllowedServicesRequest request = new RestrictAllowedServicesRequest
{
Name = "",
RestrictionType = RestrictAllowedServicesRequest.Types.RestrictionType.Unspecified,
};
// Make the request
RestrictAllowedServicesResponse response = await assuredWorkloadsServiceClient.RestrictAllowedServicesAsync(request);
}
}
// [END assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedServices_async]
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
// Copyright 2022 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 Google.Cloud.AssuredWorkloads.V1Beta1.Snippets
{
// [START assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedServices_sync]
using Google.Cloud.AssuredWorkloads.V1Beta1;

public sealed partial class GeneratedAssuredWorkloadsServiceClientSnippets
{
/// <summary>Snippet for RestrictAllowedServices</summary>
/// <remarks>
/// This snippet has been automatically generated for illustrative purposes only.
/// It may require modifications to work in your environment.
/// </remarks>
public void RestrictAllowedServicesRequestObject()
{
// Create client
AssuredWorkloadsServiceClient assuredWorkloadsServiceClient = AssuredWorkloadsServiceClient.Create();
// Initialize request argument(s)
RestrictAllowedServicesRequest request = new RestrictAllowedServicesRequest
{
Name = "",
RestrictionType = RestrictAllowedServicesRequest.Types.RestrictionType.Unspecified,
};
// Make the request
RestrictAllowedServicesResponse response = assuredWorkloadsServiceClient.RestrictAllowedServices(request);
}
}
// [END assuredworkloads_v1beta1_generated_AssuredWorkloadsService_RestrictAllowedServices_sync]
}
Loading

0 comments on commit 31b0016

Please sign in to comment.