// Copyright 2025 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. // Code generated by protoc-gen-go_gapic. DO NOT EDIT. package financialservices_test import ( "context" financialservices "cloud.google.com/go/financialservices/apiv1" financialservicespb "cloud.google.com/go/financialservices/apiv1/financialservicespb" longrunningpb "cloud.google.com/go/longrunning/autogen/longrunningpb" "google.golang.org/api/iterator" locationpb "google.golang.org/genproto/googleapis/cloud/location" ) func ExampleNewAMLClient() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() // TODO: Use client. _ = c } func ExampleNewAMLRESTClient() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLRESTClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() // TODO: Use client. _ = c } func ExampleAMLClient_CreateBacktestResult() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.CreateBacktestResultRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#CreateBacktestResultRequest. } op, err := c.CreateBacktestResult(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_CreateDataset() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.CreateDatasetRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#CreateDatasetRequest. } op, err := c.CreateDataset(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_CreateEngineConfig() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.CreateEngineConfigRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#CreateEngineConfigRequest. } op, err := c.CreateEngineConfig(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_CreateInstance() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.CreateInstanceRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#CreateInstanceRequest. } op, err := c.CreateInstance(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_CreateModel() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.CreateModelRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#CreateModelRequest. } op, err := c.CreateModel(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_CreatePredictionResult() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.CreatePredictionResultRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#CreatePredictionResultRequest. } op, err := c.CreatePredictionResult(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_DeleteBacktestResult() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.DeleteBacktestResultRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#DeleteBacktestResultRequest. } op, err := c.DeleteBacktestResult(ctx, req) if err != nil { // TODO: Handle error. } err = op.Wait(ctx) if err != nil { // TODO: Handle error. } } func ExampleAMLClient_DeleteDataset() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.DeleteDatasetRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#DeleteDatasetRequest. } op, err := c.DeleteDataset(ctx, req) if err != nil { // TODO: Handle error. } err = op.Wait(ctx) if err != nil { // TODO: Handle error. } } func ExampleAMLClient_DeleteEngineConfig() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.DeleteEngineConfigRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#DeleteEngineConfigRequest. } op, err := c.DeleteEngineConfig(ctx, req) if err != nil { // TODO: Handle error. } err = op.Wait(ctx) if err != nil { // TODO: Handle error. } } func ExampleAMLClient_DeleteInstance() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.DeleteInstanceRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#DeleteInstanceRequest. } op, err := c.DeleteInstance(ctx, req) if err != nil { // TODO: Handle error. } err = op.Wait(ctx) if err != nil { // TODO: Handle error. } } func ExampleAMLClient_DeleteModel() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.DeleteModelRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#DeleteModelRequest. } op, err := c.DeleteModel(ctx, req) if err != nil { // TODO: Handle error. } err = op.Wait(ctx) if err != nil { // TODO: Handle error. } } func ExampleAMLClient_DeletePredictionResult() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.DeletePredictionResultRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#DeletePredictionResultRequest. } op, err := c.DeletePredictionResult(ctx, req) if err != nil { // TODO: Handle error. } err = op.Wait(ctx) if err != nil { // TODO: Handle error. } } func ExampleAMLClient_ExportBacktestResultMetadata() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.ExportBacktestResultMetadataRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#ExportBacktestResultMetadataRequest. } op, err := c.ExportBacktestResultMetadata(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_ExportEngineConfigMetadata() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.ExportEngineConfigMetadataRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#ExportEngineConfigMetadataRequest. } op, err := c.ExportEngineConfigMetadata(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_ExportModelMetadata() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.ExportModelMetadataRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#ExportModelMetadataRequest. } op, err := c.ExportModelMetadata(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_ExportPredictionResultMetadata() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.ExportPredictionResultMetadataRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#ExportPredictionResultMetadataRequest. } op, err := c.ExportPredictionResultMetadata(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_ExportRegisteredParties() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.ExportRegisteredPartiesRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#ExportRegisteredPartiesRequest. } op, err := c.ExportRegisteredParties(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_GetBacktestResult() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.GetBacktestResultRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#GetBacktestResultRequest. } resp, err := c.GetBacktestResult(ctx, req) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_GetDataset() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.GetDatasetRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#GetDatasetRequest. } resp, err := c.GetDataset(ctx, req) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_GetEngineConfig() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.GetEngineConfigRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#GetEngineConfigRequest. } resp, err := c.GetEngineConfig(ctx, req) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_GetEngineVersion() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.GetEngineVersionRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#GetEngineVersionRequest. } resp, err := c.GetEngineVersion(ctx, req) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_GetInstance() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.GetInstanceRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#GetInstanceRequest. } resp, err := c.GetInstance(ctx, req) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_GetModel() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.GetModelRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#GetModelRequest. } resp, err := c.GetModel(ctx, req) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_GetPredictionResult() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.GetPredictionResultRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#GetPredictionResultRequest. } resp, err := c.GetPredictionResult(ctx, req) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_ImportRegisteredParties() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.ImportRegisteredPartiesRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#ImportRegisteredPartiesRequest. } op, err := c.ImportRegisteredParties(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_ListBacktestResults() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.ListBacktestResultsRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#ListBacktestResultsRequest. } it := c.ListBacktestResults(ctx, req) for { resp, err := it.Next() if err == iterator.Done { break } if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp // If you need to access the underlying RPC response, // you can do so by casting the `Response` as below. // Otherwise, remove this line. Only populated after // first call to Next(). Not safe for concurrent access. _ = it.Response.(*financialservicespb.ListBacktestResultsResponse) } } func ExampleAMLClient_ListDatasets() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.ListDatasetsRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#ListDatasetsRequest. } it := c.ListDatasets(ctx, req) for { resp, err := it.Next() if err == iterator.Done { break } if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp // If you need to access the underlying RPC response, // you can do so by casting the `Response` as below. // Otherwise, remove this line. Only populated after // first call to Next(). Not safe for concurrent access. _ = it.Response.(*financialservicespb.ListDatasetsResponse) } } func ExampleAMLClient_ListEngineConfigs() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.ListEngineConfigsRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#ListEngineConfigsRequest. } it := c.ListEngineConfigs(ctx, req) for { resp, err := it.Next() if err == iterator.Done { break } if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp // If you need to access the underlying RPC response, // you can do so by casting the `Response` as below. // Otherwise, remove this line. Only populated after // first call to Next(). Not safe for concurrent access. _ = it.Response.(*financialservicespb.ListEngineConfigsResponse) } } func ExampleAMLClient_ListEngineVersions() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.ListEngineVersionsRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#ListEngineVersionsRequest. } it := c.ListEngineVersions(ctx, req) for { resp, err := it.Next() if err == iterator.Done { break } if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp // If you need to access the underlying RPC response, // you can do so by casting the `Response` as below. // Otherwise, remove this line. Only populated after // first call to Next(). Not safe for concurrent access. _ = it.Response.(*financialservicespb.ListEngineVersionsResponse) } } func ExampleAMLClient_ListInstances() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.ListInstancesRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#ListInstancesRequest. } it := c.ListInstances(ctx, req) for { resp, err := it.Next() if err == iterator.Done { break } if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp // If you need to access the underlying RPC response, // you can do so by casting the `Response` as below. // Otherwise, remove this line. Only populated after // first call to Next(). Not safe for concurrent access. _ = it.Response.(*financialservicespb.ListInstancesResponse) } } func ExampleAMLClient_ListModels() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.ListModelsRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#ListModelsRequest. } it := c.ListModels(ctx, req) for { resp, err := it.Next() if err == iterator.Done { break } if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp // If you need to access the underlying RPC response, // you can do so by casting the `Response` as below. // Otherwise, remove this line. Only populated after // first call to Next(). Not safe for concurrent access. _ = it.Response.(*financialservicespb.ListModelsResponse) } } func ExampleAMLClient_ListPredictionResults() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.ListPredictionResultsRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#ListPredictionResultsRequest. } it := c.ListPredictionResults(ctx, req) for { resp, err := it.Next() if err == iterator.Done { break } if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp // If you need to access the underlying RPC response, // you can do so by casting the `Response` as below. // Otherwise, remove this line. Only populated after // first call to Next(). Not safe for concurrent access. _ = it.Response.(*financialservicespb.ListPredictionResultsResponse) } } func ExampleAMLClient_UpdateBacktestResult() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.UpdateBacktestResultRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#UpdateBacktestResultRequest. } op, err := c.UpdateBacktestResult(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_UpdateDataset() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.UpdateDatasetRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#UpdateDatasetRequest. } op, err := c.UpdateDataset(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_UpdateEngineConfig() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.UpdateEngineConfigRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#UpdateEngineConfigRequest. } op, err := c.UpdateEngineConfig(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_UpdateInstance() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.UpdateInstanceRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#UpdateInstanceRequest. } op, err := c.UpdateInstance(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_UpdateModel() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.UpdateModelRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#UpdateModelRequest. } op, err := c.UpdateModel(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_UpdatePredictionResult() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &financialservicespb.UpdatePredictionResultRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/financialservices/apiv1/financialservicespb#UpdatePredictionResultRequest. } op, err := c.UpdatePredictionResult(ctx, req) if err != nil { // TODO: Handle error. } resp, err := op.Wait(ctx) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_GetLocation() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &locationpb.GetLocationRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/location#GetLocationRequest. } resp, err := c.GetLocation(ctx, req) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_ListLocations() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &locationpb.ListLocationsRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/google.golang.org/genproto/googleapis/cloud/location#ListLocationsRequest. } it := c.ListLocations(ctx, req) for { resp, err := it.Next() if err == iterator.Done { break } if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp // If you need to access the underlying RPC response, // you can do so by casting the `Response` as below. // Otherwise, remove this line. Only populated after // first call to Next(). Not safe for concurrent access. _ = it.Response.(*locationpb.ListLocationsResponse) } } func ExampleAMLClient_CancelOperation() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &longrunningpb.CancelOperationRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/longrunning/autogen/longrunningpb#CancelOperationRequest. } err = c.CancelOperation(ctx, req) if err != nil { // TODO: Handle error. } } func ExampleAMLClient_DeleteOperation() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &longrunningpb.DeleteOperationRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/longrunning/autogen/longrunningpb#DeleteOperationRequest. } err = c.DeleteOperation(ctx, req) if err != nil { // TODO: Handle error. } } func ExampleAMLClient_GetOperation() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &longrunningpb.GetOperationRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/longrunning/autogen/longrunningpb#GetOperationRequest. } resp, err := c.GetOperation(ctx, req) if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp } func ExampleAMLClient_ListOperations() { ctx := context.Background() // 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://pkg.go.dev/cloud.google.com/go#hdr-Client_Options c, err := financialservices.NewAMLClient(ctx) if err != nil { // TODO: Handle error. } defer c.Close() req := &longrunningpb.ListOperationsRequest{ // TODO: Fill request struct fields. // See https://pkg.go.dev/cloud.google.com/go/longrunning/autogen/longrunningpb#ListOperationsRequest. } it := c.ListOperations(ctx, req) for { resp, err := it.Next() if err == iterator.Done { break } if err != nil { // TODO: Handle error. } // TODO: Use resp. _ = resp // If you need to access the underlying RPC response, // you can do so by casting the `Response` as below. // Otherwise, remove this line. Only populated after // first call to Next(). Not safe for concurrent access. _ = it.Response.(*longrunningpb.ListOperationsResponse) } }